[ZODB-Dev] Large ZODB packing and progress

Martijn Pieters mj at zopatista.com
Fri Feb 25 07:13:37 EST 2011


On Fri, Feb 25, 2011 at 12:49, Jim Fulton <jim at zope.com> wrote:
> I don't know about relstorage, but for FileStorage, commit locks are
> only held in the very last stage of packing after the vast majority of
> the work is done.  Even then, the commit lock is released periodically
> to let new transactions proceed.

RelStorage does the same; it holds the commit lock for a batch of
work, then releases it according to a configurable duty cycle.

I am working on a change that'll only hold the commit lock if it is
not already taken by something else, then release it after every batch
and re-attempt to lock. It'll only pause with packing if the lock is
already taken. That way packing will go faster when there are no other
transactions occurring anyway.

-- 
Martijn Pieters


More information about the ZODB-Dev mailing list