Amazing: EJB 3.0
Today I saw a presentation by Michael Keith that blew my socks off. It
was about the history of EJBs and the new (upcoming) EJB 3.0.
My experience with EJBs has been dismal. Every time I've tried to wade
in and understand them, I've gotten mired down with cruft, and have
lost interest. Some people that I trust had even started saying that in
a few years, EJBs would be legacy technology. On top of that, the way
people have actually been building things seems to have been diverging
further and further from EJBs (e.g.: Spring and Hibernate).
So my expectation was that EJB 3.0 would just be more incomprehensible
cruft added on the already existing incomprehensible cruft. I went to
this talk primarily so that I would hear the history and be armed to
damn EJBs once and for all.
All I can say is: wow. I never could have imagined that something as
big-corporation-driven as EJBs could do such an incredible reversal.
EJB 3.0 is so amazingly different than previous versions of EJBs that I
could look at example code and understand it immediately. I could even
imagine putting an example of this in Thinking in Java (alas, it won't
be out for some time yet, far past the book deadline, and even then
it's not clear when there will be implementations).
The original EJB spec was developed in a vacuum, based on the fantasies
of a group of people about how these things would be developed. The
reversal has come because someone (who Michael mentioned was actually
on the original team) said: let's base the new spec on what people are
actually doing, for example in Spring and Hibernate. And so it goes
from being incredibly obtuse to incredibly simple, from demanding that
you jump through hoops to jumping through the necessary hoops so that
you don't have to. It makes use of annotations and POJOs and relational
databases and all kinds of things that you want to do anyway. And the
best part is that it looks like something I want to play with, rather
than run screaming from as I have with previous versions of the EJB
spec. I actually want to use these things now.
I'm amazed. Kudos to everyone who's working on this.