Sweet! Can't wait to try them out.
Just some minor comments...
In the code where you have the javadoc comments, which I haven't seen
in a while, IIRC, you need to escape the xml examples you have.
What is this for?
+ public DatabaseBean() {
+ this.getClass();
+ }
+
-dain
On Mar 10, 2007, at 12:18 AM, David Blevins wrote:
Theeey're heeere!
On Mar 6, 2007, at 4:13 AM, David Blevins wrote:
On Mar 6, 2007, at 12:45 AM, David Blevins wrote:
Going to start wiring in the interceptor support. Probably going
to start with these two:
- OPENEJB-251: javax.interceptor.Interceptors
- OPENEJB-248: javax.interceptor.AroundInvoke
These are in! This basically means we now process the annotations
for interceptors into the respective xml. We already had some
code to process the xml, we're just missing some code to actually
wire our org.apache.openejb.interceptor code in the the containers.
Going to tackle that next.
I added some more jiras in this area to flush it out more. We now
have:
[OPENEJB-79] Interceptor classes and chain
[OPENEJB-86] Package-level Interceptors (aka Default
Interceptors)
[OPENEJB-87] Class-level Interceptors
[OPENEJB-88] Method-level Interceptors
[OPENEJB-528] Stateless Lifecycle Interception
[OPENEJB-529] Stateless Business Method Interception
[OPENEJB-530] Stateful Business Method Interception
[OPENEJB-531] Stateful Lifecycle Interception
[OPENEJB-532] MessageDriven "onMessage" Interception
[OPENEJB-533] MessageDriven Lifecycle Interception
We now have full Interceptor support!!
Interceptors are fully functional for stateless and stateful
beans. I didn't plumb them in for MDB yet as I didn't want to get
in Dain's way as he's still fighting with them -- regardless it'll
only take an hour to put the right bits in the right spots.
We support all the fancy includes and excludes and orderings -
which are a bit complicated. I'd like to write a doc and example
on it because I don't see how anyone is going to fully internalize
how all the interceptor stacking works.
The best advice for getting familiar with the new code is to read
sections 12.3.1 and 12.8.2 of the EJB 3.0 spec. Then check out
InterceptorBindingBuilder.processBindings(..) for the real guts of
that algorithm which is also javadoc'ed hopefully enough to make it
more clear.
For tests since we don't have itests yet, I whipped up two which
are also good examples of how the functionality works. Check out
StatelessInterceptorTest and StatefulInterceptorTest. In those
tests i basically build up and ejb and interceptors and feed it
straight to the deployer. We may end up seeing more of this style
of testing in the future as it's really handy to get a very
isolated environment (nice for debugging). Of course there's no
substitutes for the itests when it comes to fully testing a platform.
Everyone is strongly encouraged to pick through the code. Some
parts are pretty polished and some parts are "slapped together" :)
So there's definitely still room for creativity and improvement.
-David