February 06, 2004
What's wrong with J2EE

Mike Clark and Glenn Vanderburg have been pondering J2EE's complexity.

Now, I've been buried up to my neck in J2EE for a while now, and from this position it's easy to loose sight of the big picture. We are using lots of neat toys, each of which helps me out in one way or another, so I'm happy to have them. Since they really do all help, I'm right to be happy.

El Presidente, though, looks upon this huge list with more than a little trepidation. And he's right too; we are using a lot of tools, many of which are fairly complex. By rights, our project is a fairly simple one. What do we need all this stuff for? (And we've kept the list as short as we comfortably can, believe me!)

Well, J2EE is at least part of the problem. A simple 'Hello World' application isn't, well, simple in J2EE. Servlets, JSPs, the deployment descriptor, the WAR file, the context, and so on.

You might argue that this is because J2EE isn't designed for simple applications. And you'd be right; it's designed for complex applications; it scales well. This is true up to a point. But. But if it scaled that well, we wouldn't need all this other stuff, would we? (An MVC framework, a persistence layer, additional taglibs, etc, etc, etc.)

(OK, so, I know that J2EE has its own persistence layer: EJBs. But I've been warned off them so many times I didn't even consider them. Also, The new JSP 2.0 includes the JSTL, removing much of the need for external taglibs.)

But the other side of the problem is Java itself. I think that at heart, Glenn has it right. Java is not amenable to extension, and J2EE extends it well beyond what ESR refers to as its 'functional envelope'.

Python doesn't have a J2EE, but if it did, I suspect that it would be far simpler.

Still, I can't say I'm not having fun with all this stuff, so it isn't all bad. ;-)

Posted to Java by Simon Brunning at February 06, 2004 02:01 PM
Comments

Simon,
this is partly why I come up with my own philosophy, easy jsp. This basically means use of the minimum tools to get the job done, and not trying to build for the future, just building for today and keeping it simple.

So I use jsps, which are easy if you stick to the basics, with javabeans for database access. I try and keep it as simple as I can. No architectures, patterns, code reuse, nothing. Why.

Because in the time it would take me to learn all that stuff, I could have written the code, tested, put live, gone home and made a cup of tea.

If your shop gives you time to play with all that stuff, then fair-play to you.

But I will stick with the basic tools. If something comes along that reduces development time, and simplifies the coding, with very little learning required from me, and good results then i'll use it.

For example, IBM's dbbeans has made my database access and retrieval very simple, and I didnt have to learn very much, as the wizards in WSAD/WDSC generate classes that can show me how to use it.

I've shied away from Struts and Junit, etc, because I believe the learning curve is too high. Maybe ill come a cropper in the future, but im prepared to risk it!

Posted by: colin williams on February 6, 2004 08:59 PM

Colin,
For a simple app, that's a good idea. But it doesn't scale at all. Full on MVC/J2EE may be complex, but it certainly scales well.

Posted by: Simon Brunning on February 9, 2004 03:35 PM

There's no J2EE for Python, but you can sorta put one together for yourself.

We use Zope (which I won't recommend for such heavy lifting) in front of omniORB with a custom object-to-relational mapper. It gives us most of what J2EE has to offer our application, but we've got a couple weeks of custom development gluing everything together, and our configuration isn't quite as tidy.

Posted by: Geoff Gerrietts on February 9, 2004 11:57 PM

My view with this stuff is that the web is rapidly becoming a niche place for realtime news and rumour, catalogue shoppers and consumer product research, together with the land of blog.

When it comes down to the problem of enterprise systems. I should think everything will be ready after about 30 years of evolution, if history is a guide. By which time something radically different but innappropriate will take its place. The legacy J2EE being carted off to India for code donkeys to manage.

But IANAAG (no authorised geek) so feel free to ignore.

Posted by: jorjun on February 12, 2004 04:25 PM
Post a comment
Name:


Email Address:


URL:



Comments:


Remember info?