You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wink.apache.org by Bryant Luk <br...@gmail.com> on 2010/06/07 02:19:25 UTC
Adding release callbacks to ObjectFactory
Hi,
I'm adding some new methods to the internal ObjectFactory
(releaseInstance() and releaseAll()) which are intended to serve as
callbacks for lifecycle management of objects that were "created" from
ObjectFactory.
releaseInstance() releases a specific instance and I intend to use
this mostly for objects created during the request cycle.
releaseAll() releases all known objects created by the ObjectFactory.
I intend to use this mainly for releasing singletons at the end of the
application.
The above should help for callbacks (@PreDestroy) and JCDI and provide
a more complete lifecycle management for potentially other uses.
If anyone has any issue with this, please reply.
Thanks.
Re: Adding release callbacks to ObjectFactory
Posted by Nicholas L Gallardo <nl...@us.ibm.com>.
No complaints here. It's the right thing todo given the scenarios you
presented.
-N
Bryant Luk
<bryant.luk@gmail
.com> To
wink-dev@incubator.apache.org
06/06/2010 07:19 cc
PM
Subject
Adding release callbacks to
Please respond to ObjectFactory
wink-dev@incubato
r.apache.org
Hi,
I'm adding some new methods to the internal ObjectFactory
(releaseInstance() and releaseAll()) which are intended to serve as
callbacks for lifecycle management of objects that were "created" from
ObjectFactory.
releaseInstance() releases a specific instance and I intend to use
this mostly for objects created during the request cycle.
releaseAll() releases all known objects created by the ObjectFactory.
I intend to use this mainly for releasing singletons at the end of the
application.
The above should help for callbacks (@PreDestroy) and JCDI and provide
a more complete lifecycle management for potentially other uses.
If anyone has any issue with this, please reply.
Thanks.