We've started to implement the new Interceptor/Callback proposal that
will be reflected in the proposed final draft. It's a large change so
we'll be doing it in at least two phases.
In our initial phase we'll be updating the javax.ejb API and integrating
the latest ejb .xsd, although we won't support all the new interceptor
elements at first.
The following javax.ejb annotations will be removed :
@PostConstruct ( replaced by javax.annotation.PostConstruct )
@PreDestroy ( replaced by javax.annotation.PreDestroy )
@CallbackListener, @Interceptor ( expressed via @Interceptors instead)
We'll also be adding the mappedName attribute to the three component
defining annotations, as well as their corresponding ejb-jar.xml elements.
The main goal of this phase is to support the new converged
interceptor/callback proposal for class-level interceptors only. We'll
support all 4 callback
types(PostConstruct/PreDestroy/PrePassivate/PostActivate) and
AroundInvoke within bean classes and interceptor classes, expressed via
annotation or .xml.
What won't be supported in the first phase :
* Environment annotaitons(@EJB,_at_Resource, etc.) / injection within
interceptor classes
* Method-level interceptors
* Default interceptors
* Overriding of annotation-defined interceptor information in ejb-jar.xml
* Multiple Callbacks/AroundInvoke methods per inheritance hierarchy.
You'll need to do the following to convert any existing ejb applications :
1. Change any javax.ejb.PostConstruct/javax.ejb.PreDestroy to use the
javax.annotation ones instead.
2. Replace any use of @Interceptor with @Interceptors
3. Replace any use of @CallbackListener with @Interceptors. Also, the
signature of callback methods defined on those classes should be changed
from
void <METHOD> (Object bean)
to
void <METHOD> (InvocationContext ctx)
We're targeting tuesday/wednesday for the 1st phase checkins.
--ken