[Persistence-sig] A simple Observation API
Shane Hathaway
shane@zope.com
Wed, 31 Jul 2002 16:01:43 -0400 (EDT)
On Wed, 31 Jul 2002, Jim Fulton wrote:
> Shane Hathaway wrote:
> > But ZODB connections are not really
> > thread-specific; they may be reused in a different thread when they are
> > opened or closed. So if, for example, you registered a permanent
> > transaction participant that cleared the cache of a specific ZODB
> > connection, you wouldn't get the effect you wanted! :-)
>
> But ZODB connections are rarely used by multiple threads at the same time.
> In the model where you do associate transaction coordinators with threads,
> what you'd want to do is register a connection with a thread-global
> transaction coordinator when the connection is opened and unregister it
> when it is closed.
Ah-ha, that would work. Thanks.
Shane