Follow Slashdot stories on Twitter

 



Forgot your password?
typodupeerror
×
Java Programming

Ruby on Rails and J2EE: Room for Both? 47

Wayne writes "Ruby on Rails is a relatively new Web application framework built on the Ruby language. It is billed as an alternative to existing enterprise frameworks, and its goal, in a nutshell, is to make your life -- or at least the Web development aspects of it -- easier. This article will contrast the Rails framework against a typical J2EE implementation using common open source tools that are regularly found in enterprise applications."
This discussion has been archived. No new comments can be posted.

Ruby on Rails and J2EE: Room for Both?

Comments Filter:
  • by keesh ( 202812 ) on Monday July 18, 2005 @03:41PM (#13097027) Homepage
    Except that python doesn't even come close to ruby in terms of power. Try implementing Rails' 'belongs_to' in python... It's when you start to do neat tricks like this that the advantages of having real higher order classes (as opposed to the python Klass hack) and real higher order functions (as opposed to what python laughingly calls lambda) shows up.
  • Stupid (Score:4, Insightful)

    by jlarocco ( 851450 ) on Monday July 18, 2005 @04:16PM (#13097444) Homepage

    That's like asking C++ and Java, room for both? Or, Chevy and Ford, room for both?

    Of course there's room for both, and if there's not, who cares?

  • by ak3ldama ( 554026 ) on Monday July 18, 2005 @04:20PM (#13097476) Journal
    When will open source grow up and recognise that the the market won't support this many variations on a them?

    It's pretty simple, once a developer/group/company builds up a lot of functionality in API's or Classes, or just gains experience using one language, it is easiest and best for them to try to use that language with the new addon instead of trying to learn something new (such as RoR).

    It is not always possible or viable to use something just because it is the "great platform."

  • by Anonymous Coward on Monday July 18, 2005 @06:47PM (#13098698)
    That's like two people standing in a room and saying "is there room for us both in here?" Well, duh, you're both in there now, so yes, there's room!

    If I had a team of 50 programmers working on a gigantic site, and the programmer turnover was high, and these folks put in a good day's work but weren't hardcore programmer geeks, I would probably choose Java. Type safety, verbose explicit code, huge array of tools and vendor support, this is the stuff of "joe sixpack programmer".

    However, for small focused teams with passionate programmers (folks who program 10 hours a day at work, and then go home and do another 4 hours just for fun, and then write their own IDEs on the side), I would definitely choose Ruby on Rails. Java would just slow us down.

    And don't think for a minute that there's anything revolutionary about RoR. This is an old debate: do you create a powerful and expressive "domain specific language", which takes time to learn and understand but allows you to work at high velocity once up to speed (example: RoR)? Or do you go for slow and steady but with a quick ramp-up (example: PHP).

    The great thing about RoR is it brings this style of metaprogramming to the masses with a pragmatic language like Ruby. I love languages like Lisp, and they can blow Ruby out of the water, but try and do something simple like connect to a database and you enter a sea of incompatible confusing half-finished code and rude IRC denizens.
  • Re:RoR? (Score:3, Insightful)

    by Tobias Luetke ( 707936 ) on Monday July 18, 2005 @06:59PM (#13098853)
    Anyone experienced in ruby on rails will match any team of 5 struts programmers in productivity.

    You are absolutely and utterly kidding yourself. All idea does is fix java. An IDE like this is just not required for ruby like service pack 2 is not required for linux.
  • by Ogerman ( 136333 ) on Monday July 18, 2005 @07:43PM (#13099253)
    I love java and hibernate and all of the powerful ideas it introduces and brings to the table, but RoR just makes things so easy and fast. I don't know how easy it would be to write something huge in it..

    RoR makes easy things easy, but Java makes hard things possible. (You could also insert Python, Perl, or PHP in place of RoR and that statement would be equally true.) The "alternatives" to Java are all missing an O/R tool as powerful as Hibernate, an AOP/IoC framework as powerful as Spring or AspectJ (if they have one at all), and a UI framework as powerful as Tapestry or JSF. The IBM article in the parent post is pretty terrible because it compares Java vs. RoR for ultra simple web applications which could be feasibly implemented in ANY language. It wouldn't surprise me if RoR is an excellent alternative to PHP, but it's nowhere near an alternative to Java for that which Java does well.

    I don't see any room for .net anymore. Unless you like writing non-MVC apps :)

    Largely through copying of what has worked with Java and friends, .NET has become a very strong competitor to Java for mid/large scale applications. ..So beware of becoming too smug. And there's nothing saying that .NET apps are non-MVC. The next several years are going to have developers on each side working hard to surpass what the other is doing. If Ruby wants to compete with the big dogs, it's going to have to grow up really quickly and get some real tools in its belt. Right now, Ruby is not something you would use to write a large, complex enterprise app. At this point, the Open Source community would be far better off rallying behind Java (aka. a Free "java") than any scripting language or immature newcomer like RoR. Java needs to be improved, but it already does an enormous amount right.
  • Re:RoR? (Score:2, Insightful)

    by megajini ( 557306 ) on Tuesday July 19, 2005 @03:28AM (#13101549)

    Hell, of course the IDE has to do the stuff that Ruby does by being dynamic. Example: For ActiveRecord you would need

    • Database-Integration to generate mapping XML-files
    • A code generator to generate dumb classes (.java sourcecode) from bindings
    • Finally generate some helper classes, config and you're done
    This all results from the nature of Java. But, if you do the "generator"-way this results in much snappier applications. Currently (including Hibernate) everything circles around IOC and code injection (CGLIB), thus it's hard to clearly beat RoR. To match it (on the same field) you could enhance Groovy a bit and you would practically get the same... (because Groovy is dynamic)

    I would enjoy some more code-generation (with ant, that's not really a problem). This would be more the C-way (kind'a retro), but hell fast and very cool in a decent IDE (think of Class-Browsers, JavaDoc support...).

For God's sake, stop researching for a while and begin to think!

Working...