[ Monday, February 28, 2005 ]

"Rails is slow, J2EE is Fast" - Haven't I already heard this?

On Dion's blog, someone commented that Rails is 8x slower than J2EE (don't get me started on such benchmark figures...).
It reminded me of the old "Java is slow, C is fast" argument that I heard some years ago (I still hear it but mostly from Slashdot crowd these days). Then people realized that C and Java have their respective strength and weakness and are best used in some areas than others.

So maybe, we will realize that the same thing apply here and that Java/J2EE and Ruby/Rails serve different purposes and are better suited for different kind of web applications. Maybe, just maybe, one size does not fit all...

I'm not sure I'll build the next Google or Amazon on Rails. But there is also a range of web sites for which Rails is the way to go. Besides, it has a great quality long forgotten in the Java world: that simple things should be simple and complex things should be possible.
I developped in Java for a living and enjoy it most of the time (a little less since I was introduced to Ruby by the way) but sometimes the complexity of Java/J2EE saddens me and I'm not talking about EJB only.
I understand that there are some kind of applications which require this complexity and I contributed to it (on a J2EE server, a JMS one and a distributed transaction manager).
But there is way much more applications which don't need it and would benefit from some simplicity.
From that point of view, developping on Ruby and Rails is an eye-opener. I saw that it makes simple things simple. Now I need more time and experience with it to see if it is possible to do the complex stuff. So far, I've got a good feeling about it.

I plan to talk a little more about my (good) experience with Rails and Ruby. And the best resource from a Java perspective is Brian McCallister's Waste Of Time.

As an aside, maybe Rails is 8x slower than J2EE but it is also 10x more productive so that compensates it... What a bunch of meaningless figures!

4 Comments:

Anonymous said...

Telling 10x productive is funny. Rubby does not come close to the tool, library and IDE advantage of JAva applications. And i am not talking about EJB's here.. fashion language crowd should learn a lesson here.

3/01/2005 02:01:26 PM  
Anonymous said...

Actually, on JMS, no reason ruby cannot hook into an MQ system. I'm actually (way back burner) working on an ActiveMQ client (consumer/producer) for Ruby.

-Brian M.

3/01/2005 03:52:53 PM  
jmesnil said...

Cool Brian! That's something I'd like to see. I'm wondering what a rubyish (not rubbish!) JMS API look like.

Maybe I was not clear enough in my blog: I was not saying that you can't do complex things in Ruby. I'm sure you can. But coming from a Java perspective, I'm pleased with the simplicity of Rails which is due in big part to the use of Ruby as language.

I should have been more explicit about the differences but I tend to mix easily between platforms, language, libraries or framework.
What does Java really means? Is it the language, the runtime, rt.jar, J2EE or something else? :-)

3/01/2005 04:16:47 PM  
Anonymous said...

'Rubby (sic) does not come close to the tool, library and IDE advantage of JAva applications.'

Had it occurred to you that maybe the reason there are a lot of tools and IDEs for Java is that its a horrible language to write in?

"we don' need no steeking code generators", thanks all the same

3/02/2005 04:10:47 PM  

Post a Comment

<< Home