I have a typical CRUD Ruby on Rails app with a fairly complex model and
the performance in JRuby is 6 times slower than MRI considering median
response times. I’m running 30 minute tests with a single-threaded
client to ensure runtimes are warmed up. I’ve tried both Webrick,
warbler on JBoss and Torquebox, to no avail. I’m reaching out to the
forum hoping for some tips.
JRuby-Rack seems to take up to 150ms just to dispatch the request into
ActiveRecord activity is much slower on JRuby (by a factor of 10
JSON generation is actually faster in JRuby than MRI.
Tried jruby.compile.mode=FORCE and jruby.frameless.mode = true.
Frameless mode seems to improve performance by about 5%.
YAML serialization is slower than JSON serialization in JRuby but the
same in MRI.
JRuby runtimes are using massive amounts of memory (up to 40 MB of
garbage per request.)
I’ve tested with a single runtime in JRuby with 2 GB max heap and 512 MB
max perm size.
Any tips are appreciated.