Skip to content

Bump jruby 9.4.12.1 #17696

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

Draft
wants to merge 24 commits into
base: main
Choose a base branch
from
Draft

Bump jruby 9.4.12.1 #17696

wants to merge 24 commits into from

Conversation

donoghuc
Copy link
Member

@donoghuc donoghuc commented Jun 2, 2025

WIP: Continuation of #16986

TODO: fill out PR description and track down CI failures.

Copy link
Contributor

github-actions bot commented Jun 2, 2025

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

Copy link
Contributor

mergify bot commented Jun 2, 2025

This pull request does not have a backport label. Could you fix it @donoghuc? 🙏
To fixup this pull request, you need to add the backport labels for the needed
branches, such as:

  • backport-8./d is the label to automatically backport to the 8./d branch. /d is the digit.
  • If no backport is necessary, please add the backport-skip label

donoghuc added 2 commits June 4, 2025 15:48
Something appears to have changed in code loading where this require
is no longer in the call chain. Explicitly require it here.
@donoghuc donoghuc force-pushed the bump-jruby-9.4.12.1 branch from 6604658 to 973ff98 Compare June 4, 2025 23:52
@donoghuc
Copy link
Member Author

donoghuc commented Jun 5, 2025

I think i've got PR tests green, kicked off an acceptance test build https://buildkite.com/elastic/logstash-exhaustive-tests-pipeline/builds/1944

Next step is trying to understand the bundler and gem changes ported over from 9.4.12.0 branch.

@@ -165,7 +185,7 @@ def execute_bundler_with_retry(options)
begin
execute_bundler(options)
break
rescue ::Bundler::VersionConflict => e
rescue ::Bundler::SolveFailure => e
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@@ -29,3 +29,16 @@ def get(path, data = {}, content_type = 'application/x-www-form-urlencoded', req
end
end
end

module ::Bundler
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of patching this, i think we were just sending an object instead of a string. Modified to send along a string instead of a Gem::Platform instance.

`Caused by: org.jruby.exceptions.NoMethodError: (NoMethodError) undefined method `empty?' for #<Gem::Platform:0x637b58c9>`

@@ -48,8 +48,27 @@ def self.reset_paths!
# repository. This basically enabled the offline feature to work as
# we remove the gems from the vendor directory before packaging.
::Bundler::Source::Rubygems.module_exec do
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm having trouble understanding this patch. I wonder if it was a workaround for an upstream bug that has been fixed now? rubygems/rubygems@b9a2d4d

Experimenting with just removing the patch all together.

@donoghuc donoghuc force-pushed the bump-jruby-9.4.12.1 branch from 81ea787 to 8f1cca4 Compare June 9, 2025 23:10
This commit makes 2 changes:

1. We were sending a `Gem::Platform` instance to Thor parser instead of a
string. Convert to string version of a platform name. With newly added checks in
Thor, we were getting `noMethodError` for `Gem::Platform`.

2.  It looks like there was a patch to get around a bug in bundler that was
reaching out to the network for local gems. This appears to have been fixed
upstream, this removes the patch.
@donoghuc donoghuc force-pushed the bump-jruby-9.4.12.1 branch from 8f1cca4 to 7f97c7b Compare June 9, 2025 23:14
donoghuc added 4 commits June 10, 2025 13:57
Still validating this. Essentially ensure we check local gems when calling cache using
the updated rubygems class.
Copy link

Quality Gate passed Quality Gate passed

Issues
0 New issues
0 Fixed issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarQube

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

History

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants