Sunday, March 2, 2008

EJB Lite? Now I'm really confused...

Something smells a bit about the Java EE 6 'profiles' discussions from a few weeks back, triggered by Roberto Chinnici's blog entry here... I'm not talking about the contents of the profiles themselves -- although I do have some issues here, that's for later... what I'm talking about is this concept of EJB 'Lite'... huh?

Why is this needed? Isn't WebBeans supposed to provide a light-weight component model, without a lot of the advanced services that EJB provides such as remoting, messaging, etc, that simple websites don't require? It sounds to me that there is some major disjoint between the various JSR's that will be making up the Java EE 6 spec...

It's important to note that Roberto is very clear that the contents of this 'Lite' version is completely undefined, but let's look at the example he gives of "annotation-based programming model introduced in EJB 3.0, restricted to session beans with local interfaces (only)".

As far as I can see, the only feature that this will support that isn't explicitly defined by WebBeans is Container Managed Transactions... the WebBeans spec does define an interceptor model, and it would be relatively straight forward to provide a transactional interceptor to mimic this functionality -- I'm pretty confident that we'll see this functionality created by multiple vendors and open source projects in very little time if it's not explicitly defined in the spec...

So why the added complexity and confusion of an EJB Lite, when you have a brand-spanking new spec that is already poised to fill the need? It looks to me like a worst-case scenario of what can happen when a system is designed be committee, without any kind of strong leadership to identify this kind of problem... Can someone please introduce the Java EE JSR's left hand to its' right hand?

M

No comments: