-
Notifications
You must be signed in to change notification settings - Fork 270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
logstash-output-opensearch/2.0.3 package update #33203
logstash-output-opensearch/2.0.3 package update #33203
Conversation
octo-sts
bot
commented
Nov 4, 2024
Signed-off-by: wolfi-bot <[email protected]>
Gen AI suggestions to solve the build error: Based on the error log, the issue appears to be with the gemspec file syntax. Here are the steps to fix this:
# The error is in logstash-output-opensearch.gemspec line 53
# Shows unexpected `end` token
a. Check the gemspec file for proper Ruby syntax: # Open logstash-output-opensearch.gemspec
# Look for mismatched do/end blocks
# Ensure proper nesting of blocks
# Check for extra/missing end statements around line 53 b. Create a temporary fix in the melange YAML: pipeline:
- uses: git-checkout
with:
repository: https://github.com/opensearch-project/logstash-output-opensearch
tag: 2.0.3
- runs: |
# Add gemspec validation step
sed -i '53d' logstash-output-opensearch.gemspec # Remove problematic line
# Or fix the syntax directly
- uses: ruby/build
# Validate gemspec independently
gem build logstash-output-opensearch.gemspec
# Check Ruby syntax
ruby -c logstash-output-opensearch.gemspec
# Add verbose output to melange build
make MELANGE_EXTRA_OPTS="--create-build-log --cache-dir=.melangecache -v" REPO="./packages" package/logstash-output-opensearch
pipeline:
- uses: patch
with:
patches: patches/fix-gemspec-syntax.patch
environment:
SKIP_GEMSPEC_VALIDATION: "1" These steps should help resolve the gemspec syntax error and allow the build to proceed. |
Signed-off-by: Jason Hall <[email protected]>
Signed-off-by: Jason Hall <[email protected]>
@imjasonh Would you mind taking another look at this? It's got a new build failure and I'm not sure why since I don't have much experience working with gemspecs yet. Thanks! |
I can take a look tomorrow I have worked with logstash previously. if i fail we can escalate then. |
Our ruby/build pipeline delete all the lines contains 'signing_key' by default since it leads to build failures as the key is not available in the build environment and is not needed. ref: https://github.com/chainguard-dev/melange/blob/main/pkg/build/pipelines/ruby/build.yaml\#L42 But for version 2.0.3 and later it resutls in syntax error, unexpected end as it removes the condition line but not the full condition. Signed-off-by: debasishbsws <[email protected]>
Package logstash-8-with-output-opensearch: Click to expand/collapsePackage logstash-8-with-output-opensearch: Package logstash-output-opensearch: Click to expand/collapsePackage logstash-output-opensearch: Package logstash-8: Click to expand/collapsePackage logstash-8: Package logstash-8-compat: Click to expand/collapsePackage logstash-8-compat: Package logstash-8-bitnami-compat: Click to expand/collapsePackage logstash-8-bitnami-compat: Package logstash-8-env2yaml: Click to expand/collapsePackage logstash-8-env2yaml: |
@imjasonh The elastic test is failing but the test is passing in GHA and locally. |
Can you try giving the build more resources? |
reason: we are seeing test failure in elastic: "Error: Your application used more memory than the safety cap of 1G." Signed-off-by: Debasish Biswas <[email protected]>
Package logstash-8: Click to expand/collapsePackage logstash-8: Package logstash-8-compat: Click to expand/collapsePackage logstash-8-compat: Package logstash-8-bitnami-compat: Click to expand/collapsePackage logstash-8-bitnami-compat: Package logstash-8-env2yaml: Click to expand/collapsePackage logstash-8-env2yaml: Package logstash-8-with-output-opensearch: Click to expand/collapsePackage logstash-8-with-output-opensearch: Package logstash-output-opensearch: Click to expand/collapsePackage logstash-output-opensearch: |
assigning more resources doesn't help and we have |
…ilure Signed-off-by: Mark McCormick <[email protected]>
Package logstash-8-bitnami-compat: Click to expand/collapsePackage logstash-8-bitnami-compat: Package logstash-8-env2yaml: Click to expand/collapsePackage logstash-8-env2yaml: Package logstash-8-with-output-opensearch: Click to expand/collapsePackage logstash-8-with-output-opensearch: Package logstash-output-opensearch: Click to expand/collapsePackage logstash-output-opensearch: Package logstash-8: Click to expand/collapsePackage logstash-8: Package logstash-8-compat: Click to expand/collapsePackage logstash-8-compat: |
Signed-off-by: Mark McCormick <[email protected]>
Package logstash-8-bitnami-compat: Click to expand/collapsePackage logstash-8-bitnami-compat: Package logstash-8-env2yaml: Click to expand/collapsePackage logstash-8-env2yaml: Package logstash-8-with-output-opensearch: Click to expand/collapsePackage logstash-8-with-output-opensearch: Package logstash-output-opensearch: Click to expand/collapsePackage logstash-output-opensearch: Package logstash-8: Click to expand/collapsePackage logstash-8: Package logstash-8-compat: Click to expand/collapsePackage logstash-8-compat: |
It looks like the test is still OOMing, but looking at the metrics it's only using 2Gi each. I wonder if elastic-build is ignoring resource requests when it runs tests, and we're getting the default 2Gi allocation, which is not enough for this test. |
I've tested this theory, and the test pods are indeed getting the 12Gi request. So it might be something in the Java flags that's limiting it to 2GI. I don't know enough about Java or this package to be of any more help, but AFAICT it's not an elastic-build issue. Does the test pass locally? 🤔 |
The jvm has it's own memory size independent of the system. It looks like logstash uses |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work!