[webbeans-dev] Lifecycle for WebBeans SE Module

Peter Royle howardmoon at screamingcoder.com
Wed Sep 23 00:47:25 EDT 2009


Hi,

So does anyone think it might be generally useful to add a simple
lifecycle event which fires once the contexts are active and can be
observed by regular CDI beans? This would simplify the use case of
performing application-specific, non-cdi-extending startup events (ie:
_NOT_ things like registering new kinds of beans or injection points),
while allowing the observing method to take full advantage of all the
features of CDI.

Also, obviously, it would give the SE module its portable startup hook
back.

Or is there already a reason why this isn't such a good idea?

Cheers

Pete.


On Tue, 2009-09-22 at 20:53 -0400, Gavin King wrote:
> On Tue, Sep 22, 2009 at 8:38 PM, Peter Royle
> <howardmoon at screamingcoder.com> wrote:
> 
> > Related question: How is application code written for CDI supposed to
> > execute code on startup - does it have to register an Extension and
> > execute without any contexts/injection?
> 
> Yes, the solution for startup-time instantiation of objects is to make
> them Extensions.
> 
> 
> 




More information about the weld-dev mailing list