The runtime cache in the JRuby BSON extension is currently unsynchronized and declared as static variables leading to serious thread safety issues during BSON serialization.
https://github.com/mongodb/mongo-ruby-driver/blob/master/ext/jbson/src/main/jbson/RubyBSONCallback.java#L32
https://github.com/mongodb/mongo-ruby-driver/blob/master/ext/jbson/src/main/jbson/RubyBSONEncoder.java#L33