[Zope] Product refreshing in Zope 2.9

Dieter Maurer dieter at handshake.de
Tue Jan 31 13:41:05 EST 2006


Peter Bengtsson wrote at 2006-1-31 10:50 +0000:
> ...
> if RefreshFuncs.performFullRefresh(self._p_jar, self.id):
>    from ZODB import Connection
>    Connection.resetCaches() # Clears cache in future connections.

The call above is responsible to clear the ZODB caches.

After your problem description corrections, it appears as if
you were still accessing an old object.

Two possibilities:

  *  "resetCaches" no longer works reliable

  *  you access the object from somewhere else then
     the ZODB cache (e.g. you store a persistent object
     on module or class level)

> ...
>If someone can guide me I'd like to dig deeper into
>ZODB.Connection.resetCaches() to see if there's be a big difference in
>version 3.6 that might have caused my beloved refresh to stop working.

"resetCaches" will almost surely only increment a number.

The true cache flush happens in "Connection._setDB".
Look there.

-- 
Dieter


More information about the Zope mailing list