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 <[EMAIL PROTECTED]> 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: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Howard M. Lewis Ship Independent J2EE / Open-Source Java Consultant Creator, Jakarta Tapestry Creator, Jakarta HiveMind http://howardlewisship.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
