[cdi-dev] LifeCycle Event Callbacks and Interceptors

Pete Muir pmuir at redhat.com
Wed Jun 1 08:19:16 EDT 2011

>From 7.2 of the CDI spec:

"Invocation of lifecycle callbacks by the container are not business method invocations, but are intercepted by intercept- ors for lifecycle callbacks."


"If, and only if, an invocation is a business method invocation it passes through method interceptors and decorators"

So the CDI spec is fairly clear that around invoke interceptors are not called for lifecycle callbacks IMO. If you want this clarified, please open a CDI issue + provide a patch/pull req for suggested changes (as I see it, it's quite clear so I wouldn't know how to improve it ;-).

On 30 May 2011, at 23:21, Jens Schumann wrote:

> Hi all!
> Recently I have noticed that OWB does not apply (class/method)
> interceptors to lifecycle event callback methods. I 've chatted with Mark
> and he referred me to the list. He tried to remember his research on this
> topic and made the point that class interceptors should probably be
> applied. However he has the feeling that pure method interceptors may not
> be applied for lifecycle event callback methods since those methods are no
> business methods.
> It seems that neither the CDI spec nor the interceptor spec covers the
> topic for all variations. After reading the interceptor spec again
> (chapter "Interceptors for LifeCycle Event Callbacks") I would follow
> Marks assertions.
> What do you think? Is there anything missing within the CDI spec (and OWB
> of course)?
> Jens
> _______________________________________________
> cdi-dev mailing list
> cdi-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/cdi-dev

More information about the cdi-dev mailing list