You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hivemind.apache.org by "Hensley, Richard" <Ri...@McKesson.com> on 2004/08/27 20:59:25 UTC
Tapestry and Hivemind
How would I inject the my tapestry Visit for the current request into a
hivemind service?
I would expect that each time a service calls a Visit method, the Visit that
is for the session that called the service is used.
I think I should be able to do the following:
Make a VisitSource service with a getVisit() method.
Inject the getVisit() property into my service that needs the visit
The tricky part is implementing the VisitSource service correctly. I need
some ideas.
Richard
---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-user-help@jakarta.apache.org
Re: Tapestry and Hivemind
Posted by Howard Lewis Ship <hl...@gmail.com>.
I'm not sure how it would be done in Tapestry 3.1, never mind 3.0.
I think your best bet is to store the IEngine inside HiveMind using an
EngineHolder interface (i.e., getEngine(), setEngine()). Find a place
(perhaps an IMonitor) that can store the engine ... make the
EngineHolder service threaded.
>From that you can get the current IEngine, and from that, the current Visit.
Alternately, just make the Visit a parameter to the service methods
you will invoke.
On Fri, 27 Aug 2004 14:59:25 -0400, Hensley, Richard
<ri...@mckesson.com> wrote:
> How would I inject the my tapestry Visit for the current request into a
> hivemind service?
>
> I would expect that each time a service calls a Visit method, the Visit that
> is for the session that called the service is used.
>
> I think I should be able to do the following:
>
> Make a VisitSource service with a getVisit() method.
> Inject the getVisit() property into my service that needs the visit
>
> The tricky part is implementing the VisitSource service correctly. I need
> some ideas.
>
> Richard
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: hivemind-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: hivemind-user-help@jakarta.apache.org
>
>
--
Howard M. Lewis Ship
Independent J2EE / Open-Source Java Consultant
Creator, Jakarta Tapestry
Creator, Jakarta HiveMind
http://howardlewisship.com
---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-user-help@jakarta.apache.org