While working on https://github.com/fidothe/saxon-rb I hit errors in production using a semi-experimental branch (https://github.com/fidothe/saxon-rb/tree/error-reporting) in a threaded XML-processing program.
The errors were the same
NoMethodError: undefined method __jcreate_meta!' as in https://github.com/jruby/jruby/issues/6160, and the program structure is almost identical save for some loading indirection thanks to the use of
I am running it in a CI-type environment where 20+ EC2 instances are spun up to process a large amount of data. Most, but not all, runs I'd have one instance's process crash with the error.
Creating an instance of the problem class (https://github.com/fidothe/saxon-rb/blob/error-reporting/lib/saxon/error_reporter.rb,
EgClass in this reproduction case) on the main thread, rather than in the worker threads, has made the problem vanish entirely.