Hi there,

Brian Sutherland wrote:
Also for this problem:

    # XXX what happens if EngineFactory were to be evicted from the ZODB
    # cache?
    def getCached(self):
        return getattr(self, '_v_engine', None)

I think you could use the same mechanism found in zope.app.cache.ram.
I.e. store the engines in a module level global dictionary. Then use
some clever way (with a counter and time) to figure out a unique key for
your local utility (and persistently store the key).

Ah, thanks for that tip. Does zope.app.cache.ram deal with threading issues? Ah, yes, I see it uses a lock. Anyway, a patch would be welcome. :)



Zope-Dev maillist  -  Zope-Dev@zope.org
**  No cross posts or HTML encoding!  **
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope )

Reply via email to