You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hivemind.apache.org by "Liebig, Stefan " <St...@compeople.de> on 2005/01/10 11:04:33 UTC
Trying to create a ´new instance" service model, but ..
I tried to create a ´new instance´ service model. This service model should
create for each service request a new instance. But as I found out this is
not possible because ServicePointImpl ´caches´ the service once created.
My question - independent on how usefull a ´new instance´ service model might
be - is:
Shouldn´t this caching not be part of the specific service model? I think the
current solution limits the usage of service models.
Stefan
email: stefan.liebig@compeople.de
---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-dev-help@jakarta.apache.org
Re: Trying to create a ´new instance" service model, but ..
Posted by Howard Lewis Ship <hl...@gmail.com>.
A good name for this would be "prototype", because that's what Spring
uses for the same concept.
Look at how ThreadedServiceModel works.
You basically need a proxy that obtains a fresh instance from the
ServiceModel for each method invocation.
On Mon, 10 Jan 2005 02:04:33 -0800, Liebig, Stefan
<St...@compeople.de> wrote:
>
> I tried to create a ´new instance´ service model. This service model should
> create for each service request a new instance. But as I found out this is
> not possible because ServicePointImpl ´caches´ the service once created.
>
> My question - independent on how usefull a ´new instance´ service model might
> be - is:
> Shouldn´t this caching not be part of the specific service model? I think the
> current solution limits the usage of service models.
>
> Stefan
>
> email: stefan.liebig@compeople.de
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: hivemind-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: hivemind-dev-help@jakarta.apache.org
>
>
--
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Jakarta Tapestry
Creator, Jakarta HiveMind
Professional Tapestry training, mentoring, support
and project work. http://howardlewisship.com
---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-dev-help@jakarta.apache.org