If those (the dynamic nature and being good for dsls) are the only things going for Ruby, then groovy might be a better recommendation. Java to Groovy is a pretty much instant transition, whereas there is a (slight) learning curve for Ruby.
That said, I really like Ruby and find it a joy to program in, even if these days I'm doing more groovy work.
Personally I think your choice of a language comes down to many factors. For me, Ruby is probably the most fun I've had developing in any language, and that means a lot. I've also received dramatic productivity boosts since moving over. There are certainly a few things that aren't perfect, but that's true of any language.
If you're coming from a Java background and interested in getting your feet wet with Ruby you may also want to take a look at JRuby. It runs in the JVM, can leverage existing Java classes, and deployment will be familiar -- it can be packaged and served as a WAR. And yes, it can run Rails.
Unfortunately I haven't had the time to play around with Groovy, so I can't make an informed comparison. I'd love to hear other peoples' thoughts on the matter though!
sumeet gupta
Ranch Hand
Joined: Aug 31, 2008
Posts: 33
posted
0
HI,
I m pretty new to ruby.Can anyone refer me some books for jruby?
Nick Plante
author
Greenhorn
Joined: Sep 01, 2008
Posts: 13
posted
0
Although I haven't personally read it, Ola Bini's JRuby on Rails book might be a good start. I actually have a copy but just haven't found the time to dig in!