I would love JRuby to be a solid Ruby implementation that can  
leverage the investment in Java/JVM debugging/performance/profiling  
tools. But here's an example where it would be very useful:

I am writing a monitoring application that exposes information about  
a Java based application, Sonic MQ JMS broker, and the underlying OS  
status. Ruby makes trivial work of parsing sar output, or scraping / 
proc files. The Sonic management API however is an untyped JMX style  
API. I first tried to use a Java/Sonic CLI program and have my Ruby  
code run it with popen3 etc but had challenges making this stable. I  
then tried the Java Ruby Bridge which was great but had unexplained  
failures and my Ruby isn't strong enough to diagnose. I then used  
Ruby to drive a Java servlet wrapper on the JMS api, and then ended  
up writing a hard-coded specific Java app that logs the subset of  
attributes I am interested in to a file and I have a decoupled Ruby  
script that reads this. That is four hacks that each sucked in  
different ways. Using Ruby to in-process call the Java code is the  
least sucky approach by far.

Is JRuby ready to have a threaded Ruby app use threaded Java code  
effectively?

Peter



On Nov 11, 2006, at 6:12 PM, M. Edward (Ed) Borasky wrote:

> David Vallner wrote:
>> M. Edward (Ed) Borasky wrote:
>>
>>> Well ... I know how *I* feel about it:
>>>
>>> http://borasky-research.blogspot.com/2006/11/nitty-gritty-of- 
>>> ruby_11.html
>>>
>>>
>>
>> Impose JRuby on the world? I have my doubts Sun would even try - the
>> time of Java hype marketing is past.
> Well, the original poster wanted jRuby to be the one true way. I  
> was simply saying that wasn't possible; even Sun couldn't do it. I  
> too doubt if they would try. But Sun is a big enough company to try  
> things that might not necessarily work.
>
> The time of Java hype marketing is past? Maybe, but the language  
> seems to be an 800-pound gorilla in some peoples' minds. I can't  
> imagine Sun *not* doing everything they can to insure that jRuby  
> succeeds and wins business for Sun.
>
>> And I don't think JRuby will be as
>> earthshaking to both the Ruby and Java worlds as some people make  
>> it out
>> to be. By adopting JRuby as the implementation language for the Java
>> platform, you are also partially dropping the advantages that  
>> keeping to
>> Java has (existing infrastructure, experience, tool support). In the
>> end, it might be a useful tool on both sides, but I don't see  
>> paranoid
>> managers adopting Ruby en masse just because it has a J prepended  
>> to it
>> - not all of them are that gullible.
>>
> Again, *I* don't support dropping other implementations of Ruby. If  
> nothing else, Microsoft will make at least one release of at least  
> one Ruby implementation. And I'm sure Matz and Koichi will continue  
> leading the community path.
>
> What I'm *not* sure about is whether Rubinius  will flourish.  
> Cardinal seems pretty much dead, but I think there's a lot of  
> energy behind Rubinius.
>> That the JVM become the primary runtime for Ruby is somehow  
>> laughable.
>> So far, it hasn't become the primary runtime for any major  
>> programming
>> language that isn't Java, evidence would suggest that this remains  
>> the
>> case. It would be foolish for performance reasons if nothing else, a
>> dedicated optimised VM will do better when treated with Ruby
>> idiosyncratisms like pervasive use of closures.
>>
> But we're talking about two different things here -- a community  
> and commercial enterprises. The community can afford to strive for  
> perfection. Commercial enterprises can not. They must *satisfice*,  
> not optimize!
>
>> The signal-to-noise ratio of blog topics that concern both Java  
>> and Ruby
>> has been abysmal unless it was about JRuby in specific, I hate to see
>> random opinionated rants and wishful thinking cloud that topic too.
>>
> Still, you have to acknowledge that jRuby is now a commercial  
> project funded by a major hardware and software vendor. That's  
> going to draw opinions and rants and wishful thinking and love and  
> hate and arguments and FUD. I'm surprised someone from Microsoft  
> hasn't attacked it publicly yet.
>
> jRuby is an investment. Only time will tell whether that investment  
> will pay off and what the payoffs will be. I don't know enough  
> about the Java runtime (or the CLR or Parrot, for that matter) to  
> predict success or failure. I'm personally much more interested in  
> the open source community efforts. There are many more  
> opportunities for me to create signal there than there are in two  
> corporations, neither of which pays me a dime. :)
>
> -- 
> M. Edward (Ed) Borasky, FBG, AB, PTA, PGS, MS, MNLP, NST, ACMC(P)
> http://borasky-research.blogspot.com/
>
> If God had meant for carrots to be eaten cooked, He would have  
> given rabbits fire.
>
>