On Thu, 16 Aug 2012 16:21:58 -0300, Lenny Primak <lpri...@hope.nyc.ny.us> wrote:

On Aug 16, 2012, at 2:03 PM, Michael Prescott <michael.r.presc...@gmail.com> wrote:

Just want to check my understanding on a few matters.

Pages and components are pooled and cleaned up between requests, so it's
fine to use fields for storage during request procesing (e.g. loop
variables), or as gateways to session state (e.g. fields marked with
@SessionState).

Not quite. Pages and components are singletons, but the fields inside pages are re-written to be thread local so they don't trash each other and get cleaned up after every request unless @Persisted.

Pages were pooled until 5.1.0.5. Since Tapestry 5.2, they're implemented as Lenny described above and no *pooling* is done. Components were never pooled, just whole pages including their embedded component instances..

For Tapestry-hibernate, it's okay to @Inject a hibernate session into a
service, however, because the session implementation you get is a service defined with per-thread scope, so you don't get bleed between requests.
Yes

Services defined based on interfaces are proxied and this proxy invokes the correct service instance for that thread.

--
Thiago H. de Paula Figueiredo

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to