Hi Nitin,
I understand what you say. Well, in fact I was able to find the around-invoke , pre-passivate and post-activate elements of the deployment descriptor: take a look at page 536. It is defined so that they may be specified inside sessionType or interceptorType elements. But the post-construct and pre-destroy are nowhere to be found.
In fact, inside the definition of the interceptorType element there is a documentation element that reads:
The interceptorType element declares information about a single interceptor class. It consists of :
- An optional description.
- The fully-qualified name of the interceptor class.
- An optional list of around invoke methods declared on the interceptor class and/or its super-classes.
- An optional list environment dependencies for the interceptor class and/or its super-classes.
- An optional list of post-activate methods declared on the interceptor class and/or its super-classes.
- An optional list of pre-passivate methods declared on the interceptor class and/or its super-classes.
Again, the post-construct and pre-destroy elements are not mentioned.
This is not what the specification states in section 12.4:
If the deployment descriptor is used to define interceptors, the post-construct, pre-destroy, post-activate, and pre-passivate elements are used.
Furthermore, section 12.8.1 makes the following "mistake":
The interceptor methods are specified by using the around-invoke, pre-construct, post-destroy, pre-passivate, and post-activate elements.
Note it talks about pre-construct (vs. post-construct) and post-destroy (vs. pre-destroy).
This is confusing.
[ September 01, 2008: Message edited by: Sergio Tridente ]