[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openejb-development
Subject:    Re: InitHooks
From:       Romain Manni-Bucau <rmannibucau () gmail ! com>
Date:       2012-06-22 6:44:49
Message-ID: CACLE=7ObihRoMC37Pd5WY+cx=zrexFweudoWw5c_E6C7AeDXhg () mail ! gmail ! com
[Download RAW message or body]


Yes. Simplr needs yo creaye the event and to fire it
Le 22 juin 2012 03:21, "Karan Malhi" <karan.malhi@gmail.com> a =E9crit :

> This is nice stuff. Was wondering if there could be a possibility to exte=
nd
> it to a full-fledged event model for other  events in the container.
> Examples could be "PreDeploy", "PostDeploy" , etc
>
> On Wed, Jun 20, 2012 at 5:03 PM, Romain Manni-Bucau
> <rmannibucau@gmail.com>wrote:
>
> > both are on trunk
> >
> > observer have an alias, class name for observers defined in tomee.xml a=
nd
> > name of the file containing the class name in
> > META-INF/org.apache.opeenjb.observer for the ones found by scanning.
> >
> > One observer can be added only once (if one day we scan application too
> it
> > can avoid some weird stuff).
> >
> > - Romain
> >
> >
> > 2012/6/21 David Blevins <david.blevins@gmail.com>
> >
> > >
> > > On Jun 20, 2012, at 4:16 PM, Romain Manni-Bucau wrote:
> > >
> > > > META-INF/ or Openejb but not both, no?
> > >
> > > Maybe we start with META-INF and see how far we get.
> > >
> > >
> > > -David
> > >
> > > >
> > > > 2012/6/21 David Blevins <david.blevins@gmail.com>
> > > >
> > > >>
> > > >> On Jun 20, 2012, at 12:04 PM, David Blevins wrote:
> > > >>
> > > >>> Let me take a shot at a slightly different approach.  Something
> like
> > > >> what we did the client with a CDI-like observer pattern.  As I
> > > mentioned in
> > > >> that email, we might want to do it in the server as well.  Sounds
> > like a
> > > >> good time to try it out.
> > > >>
> > > >> Updated the code so that SystemInstance has the observer
> functionality
> > > >> built-in.
> > > >>
> > > >> We have the following events now:
> > > >>
> > > >>
> > > >>
> > >
> >
> container/openejb-core/src/main/java/org/apache/openejb/assembler/classic=
/event/AssemblerCreated.java
> > > >>
> > > >>
> > >
> >
> container/openejb-core/src/main/java/org/apache/openejb/assembler/classic=
/event/AssemblerDestroyed.java
> > > >>
> > > >>
> > >
> >
> container/openejb-loader/src/main/java/org/apache/openejb/loader/event/Co=
mponentAdded.java
> > > >>
> > > >>
> > >
> >
> container/openejb-loader/src/main/java/org/apache/openejb/loader/event/Co=
mponentRemoved.java
> > > >>
> > > >>
> > >
> >
> container/openejb-loader/src/main/java/org/apache/openejb/observer/event/=
ObserverAdded.java
> > > >>
> > > >>
> > >
> >
> container/openejb-loader/src/main/java/org/apache/openejb/observer/event/=
ObserverFailed.java
> > > >>
> > > >>
> > >
> >
> container/openejb-loader/src/main/java/org/apache/openejb/observer/event/=
ObserverRemoved.java
> > > >>
> > > >>
> > > >> Temporarily removed the code in the ConfigurationFactory where we
> were
> > > >> creating and installing observers.  It's fine code to have, we jus=
t
> > > need to
> > > >> move that into the Assembler as that's it's job (to create the
> things
> > > >> defined in the openejb/tomee.xml file).  We just need to update th=
e
> > > >> FacilitiesInfo to have a collection of observerInfo.  We should
> > probably
> > > >> allow the Observers to have dependency injection and just treat th=
em
> > as
> > > >> another kind of ServiceInfo.
> > > >>
> > > >> Well probably want to add a META-INF/ loading mechanism as well.
> > > >>
> > > >>
> > > >> -David
> > > >>
> > > >>
> > >
> > >
> >
>
>
>
> --
>
> Karan Singh Malhi
> twitter.com/KaranSinghMalhi
>


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic