Java the SUV of web deveopment tools
blogs.law.harvard.edu
blogs.law.harvard.edu
For years blub programmers have won decision-making arguments against hackers by convincing the boss "Java is Enterprise" and proper hacker languages are only for "sloppy work". People are finally realizing how hollow those great-sounding promises were.
VINDICATION IS NIGH.
A Java IDE in a sense "knows" what you're writing and helps you avoid making mistakes while you're coding.
People complain about too much boilerplate code in java - that's true, but it can actually be a good thing in the same way comments can be a good thing, and IDEs generate all the boilerplate for you with just a couple of keystrokes (whereas comments don't write themselves).
I'm curious whether the Java bashers out there have ever used a good IDE like Eclipse or IDEA for any extended period of time. Because if you're using a text editor like emacs, programming in Java can seem ridiculously difficult. Conversely it might seem ridiculously difficult for a person accustomed to an IDE to use a text editor for a scripting language.
Coding Java without an IDE is like trying to control the space shuttle with a steering wheel. Once you've mastered all the features of an IDE, however, (which can take years, but then again so does learning emacs) programming in Java becomes a breeze and you get all the benefits of static typing (with the safety and tools it enables) and the vast Java libraries with no extra difficulty coding compared to a simpler language.
Right now you can get similar behavior with anonymous inner classes, but it leads to more clutter than necessary.
This demonstrates another good argument in favor of java - it is always evolving to make programming in it more enjoyable. It was difficult to use collection classes at first, but version 1.5 introduced generics. It sucked to use the iterator pattern with collections, but now java has a "for each" loop. It sucked not having enums, but now Java has them too, etc. Not to mention that every new Java release brings a ton of new library classes and enhancements.
Its unfortunate few of the web hacker types see Java as anything but an "Enterprise" language. Admittedly, JSP (and even JSF) sucks. So the negative wrap that Java gets as a web development language is understandable.
But I think GWT will change that eventually... Build and build, Unit test, and never worry about browsers or the nasty stuff typically related with Ajax-centric development. To me that is worth its weight in gold.
It alleviates some of the cross-browser headaches, but doing anything nontrivial can still hit browser differences, especially with styles and layout.
The only viable browser-worry-free platform seems to be Flash right now.
Lets hope the bugs continue to get ironed out. I know 1.4 will fix quite a few of the minor things.
I think the big deal is the RPC stuff with GWT. While it still has a way to go in terms of customizability, it is extremly powerful none the less. As far as Flash + GWT, I think its pretty sweet doing asynchronous calls via JSON messages between the two. Quite a powerful combination..
You say this as if it was a good thing. Consider the effort, months or years from now, in reading, understanding and modifying all that generated boilerplate.
A better language does not require the boilerplate in the first place.
My guess is that students who are actually experienced with web apps will avoid Java like the plague due to the horrible rap it has in the web development community (from people like Greenspun). Meanwhile, those who are less clued in are going to choose the language they're comfortable with, namely Java.
I feel even more confident in that explanation given that he lists C#/.NET as a good language. Syntax-wise, Java and C# are extremely similar, and performance-wise C# might have an edge, but not to the point where it would affect the goodness of apps. The complexity of their respective stacks is pretty similar as well.
Moral of the story is, good hackers can make good software in any language you throw at them, and bad coders will not. I suppose there are aspects of stacks, like RoR, which will make it easy for bad coders to put something respectable together, but I seriously can't see Java as inhibiting great people from making great things.
Dont underestimate the time from idea to a rapid prototype. For a programmer, at least me, its very rewarding when that is kept short.
"The challenge for platforms like Ruby is to match these platforms and establish and develop a strong deployed base so that they become the entrenched platform of choice."
I'd say the challenge is not for Ruby to match those platforms, rather for Ruby developers to create products that make all the Java/.NET stuff obsolete. His comment makes a lot of sense if you start with the assumption that there's some X amount of code to write and maintain, and that a large corporation won't want to switch to Ruby. He's right. But that doesn't mean they won't want to switch to a product that eliminates the need for maintenance altogether.
The trick is, of course, figuring out how to outsell the Oracle salesman. http://www.paulgraham.com/start.html
I think Java still has a lot of things going for it, and my most favorite aspect is the documentation. I never spent a dime on Java books because there is so much excellent documentation available online (starting with the Java Tutorial for beginners). Compare that to Ruby, where you can't even get a specification of the current state of the language for free.
Also it seems most of the new developments in IT are being developed for Java first these days, like Aspect Oriented Programming, Dependency Injection and whatever (granted, maybe some of these things would be superfluous in other languages to begin with, I don't know). You get a really good IDE for free (Eclipse), and new add-ons and frameworks for Java are almost forced to also provide plugins for the IDE to work with. For LISP you are still supposed to use Emacs. What do you use for Ruby on Rails?
That said, it seems to me the problem with Java is not the language but the people using it. There is a lot of overengineering going on, that just isn't fun anymore. Many people (especially the bosses in the large corporations) have become dogmatic about certain ways to design applications, that are often inappropriate (in my opinion).
I also long for a faster way to prototype, and I am putting a lot of hopes on Groovy+Grails or even Ruby. But I have the impression that many people who bash Java don't really know it.
"But I have the impression that many people who bash Java don't really know it."
Interesting complaint from someone who just bashed Perl and almost certainly doesn't know it well.
I am not saying that there can't be valid reasons for hating Java. I just think most of the times it is rather the specific frameworks than the language itself that pisses people off. For example I can't bring myself to write EJBs - having to create 5 files just to be able to call a method remotely exceeds my pain tolerance. Yet in many big cooperations someone up in the management chain has decided that every Java Application has to use EJBs. That I hate, too. It's misleading to judge Java based on that perversity, though - EJBs are just a framework written in Java, not the Java programming language.
Anyway, out of curiosity, is Perl still relevant today? Why would people choose Perl over Python or Ruby?
From your description it sounds like you were frustrated by coding horrendous Perl and instead of learning it you moved to a language with training wheels. I'd rather just fall a few times while I'm learning so I can go much faster afterwards.
"Why would people choose Perl over Python or Ruby?"
It's fast in productivity and performance. There are great books. It's on every Unix machine. CPAN still reigns supreme as the ultimate library repository. These days there's some great frameworks for web development, my favorite being Catalyst with DBIx::Class and Template Toolkit.
Ruby is mostly just Perl without all the mental baggage of people seeing bad Perl code for years. The way a restaurant might avoid saying "squid" and instead say "calimari" -- it sells a lot better.
Also whenever I take on a new programming contract, I just start the computer the company provides me with, download the Java documentation and off we go.
Fad paradigms: no, but I know that if I need something, someone has already written a framework for it.
You're moving from a verbose, bloated, over-engineered system to a terse and simple system. I think you're looking for something that doesn't exist because it's not how Ruby programmers work -- they use a language small enough to actually keep in your head and that's a huge part of the productivity to be had.
My ride with RoR hasn't been smooth so far. Far from having my first web app running within minutes. Instant Rails didn't work at all, and I spent hours trying to find a database driver for MySQL for Ruby. It's all very confusing. I suspect there is already a database driver bundled with RoR, but how would I know (documentation, where are you)? Googling only led me to some strange page where you could compile your own driver from C source code (and with what compiler, if I am on windows), which presumably was in some kind of alpha stage.
At least with Java I know that there usually exists a stable and proven solution... The training wheel analogy was maybe not so bad at all: Java applications just tend to be more stable than the scripting stuff. And other than bikes with training wheels in the real life, Java is also faster.
Err.... http://www.ruby-doc.org/
"What do you use for Ruby on Rails?"
Textmate. :-)
BTW, you might want to have a look at JRuby. While it's still pre-1.0, it's moving along nicely. It will allow you to leverage all your knowledge of the Java class libraries.
You mean, as opposed to Perl, which doesn't work?
That's the most ridiculous thing I've heard on this forum.