JRuby 9.4.10.0 Released

Tuesday, January 21 2025

The JRuby community is pleased to announce the release of JRuby 9.4.10.0.

JRuby 9.4.x targets Ruby 3.1 compatibility.

Thank you to our contributors this release, you help keep JRuby moving forward!

Ruby Compatibility

  • Fixed a NegativeArraySizeException crash parsing heredocs. #8355, #8557
  • Users can now opt into Ruby 3.3 behavior for NoMethodError and NameError that no longer inspects the target object. This inspect frequently led to memory issues. Specify JRuby flag -XnameError.inspect.object=false or JVM property jruby.nameError.inspect.object=false to disable the inspect call. #216, #8384, #8538
  • Implemented the missing Process.argv0 method, used by recent Bundler releases. #8568, #8570

Standard Library

  • The jar-dependencies gem, responsible for fetching jar file dependencies of Ruby gems, can now be updated independently of JRuby. #7262, #8488, #8502
  • An upcoming release of jar-dependencies, will fix issues sourcing jar dependencies in container deployments (partially fixed previously by an updated ruby-maven-libs gem). #7059, #8366
  • The psych gem is updated to version 5.2.3, including a fix for YAML aliases from SnakeYAML-Engine version 2.9. #8352, #8575
  • The reline gem is updated to 0.5.12. #8481

Java Integration

  • Only JVM classes imported from the same classloader hierarchy as JRuby will be bound to constants in JRuby’s package hierarchy. #8156
  • Implementing a Java interface no longer leads to constant redefinition warnings. #8349, #8503
  • Precompiled Ruby scripts now properly prepare optimized homogeneous case/when statements. Previously they would deserialize incorrectly and garble the branches. #8421, #8424

Performance and Usability

  • Additional runtime data structures are eagerly cleared when tearing down a JRuby runtime, aiding GC. #8343, #8566
  • The JRuby shell-based launcher script now properly handles JRuby installed in a path with spaces. #8441, #8442
  • The Class#subclasses method has been optimized to eliminate it as a bottleneck in complex ActiveRecord STI queries. #8457, #8462
  • Integer multiplication operations that overflow outside of int64 range have been optimized to eliminate heavy exception raises. #8516, #8523

Issues and PRs resolved for 9.4.10.0