[ZODB-Dev] More "cPickleCache.incrgc" control (was: [Problem]
"_v_" variables too volatile)
Dieter Maurer
dieter at handshake.de
Sun Feb 8 13:05:53 EST 2004
Christian Robottom Reis wrote at 2004-2-8 12:25 -0200:
>On Sat, Feb 07, 2004 at 05:33:39PM +0100, Dieter Maurer wrote:
>Content-Description: message body and .signature
>> In Dec. 2003, we have had an interesting discussion on how to provide
>> more "incrgc" control -- especially how to prevent "_v_" variables
>> to be flushed at subtransaction boundaries.
>
>Dieter, I've been toying with this over the weekend, and I haven't been
>able to find a reproducible case where this happens to write a testcase.
>Can you outline an access pattern which causes a _v_ variable to be
>flushed upon a commit(1)/abort(1)?
It is not easy to reproduce.
In real life,
it usually happens, when your ZODB cache bounds are tight and
you use subtransactions (they are used, e.g., when
you index large amounts of objects).
To reproduce it, you can look at my test cases for
the new feature (class "StickyTests" in "ZODB/tests/testCache.py").
They set up a "ZODB.DB" with "cache_size=0".
In this scenario, all objects with "_v_" variables that
have not been modified will be invalidated by
a subtransaction commit. Invalidation looses the "_v_"
variables.
--
Dieter
More information about the ZODB-Dev
mailing list