4 ms·
I've been eyeing jruby for quite a while but never had much success with it. There seems to always be the odd gem not supporting it (e.g. jruby-openssl is broke
by moe 15y ago
I've been eyeing jruby for quite a while but never had much success with it. There seems to always be the odd gem not supporting it (e.g. jruby-openssl is broken which a lot of my stuff depends on).
- kennystone 15y agoInvoke dynamic means less of a need for C-Extensions, which is probably one of the largest sources of pain for JRuby compatibility. The JVM is better at running plain old ruby code now, so there's less need to go outside of it with C or Java.
- tedunangst 15y agoWell, you don't need extensions, but lots of library interfaces still use them because they haven't been updated to FFI. So sometimes you can't use the code you want. The good news is that it's usually pretty painless to whip up your own FFI binding.
- headius 15y agoWe've been very lucky to have a lot of ingenious JRuby users help port some of those extensions or produce API-compatible wrappers around equivalent Java libs. There's still C exts we don't have equivalent JRuby exts for, but things are much better than they used to be.
- headius 15y agoThat's definitely our hope. JRuby has come further than any implementation in making Ruby fast enough to replace C or Java, and if it's possible to write more in Ruby then all implementations will benefit. C extensions are the number one thing holding the C/++ implementations back.
- bascule 15y agojruby-openssl has worked fine for me for several years. Making outgoing SSL connections was one of the primary functions of the last app I worked on.
- moe 15y agoIt could indeed be that my jruby endeavors just happened at unfortunate times. The jruby-openssl bug that I'm currently seeing is a different one from last time - and it's apparently fixed in git-HEAD already, just not in the gems yet. So I'm looking forward to the 0.7.5-release and with a bit of luck I might finally be able to jump on the jruby-bandwagon then.
- headius 15y agoOpenSSL is a terribly complex library to support, but we've managed to steadily improve our pure-Java port (originally a herculean effort by Ola Bini, it wraps bouncycastle in an OpenSSL-lookalike API). There's still probably issues, but we have tried to fix them as they come up.
- moe 15y agoYes, that was no criticism, I'm hoping jruby will succeed. Fwiw, I'm currently blocked on http://jira.codehaus.org/browse/JRUBY-6260 http://jira.codehaus.org/browse/JRUBY-6260 Apparently the fix is already done but hasn't made it into the 0.7.5dev gem yet.