for those of you watching the commit lists closely I made a branch at:


which uses a very simple approach to using the pickle protocol version 2
in all parts of the ZODB by externalizing it into a constant in
config.py and changing all protocol versions from a hardcoded 1 into
using the constant.

My main motivation was to see how much work this would be and see the
actual size reduction / speed improvement this could bring.

After doing benchmarks with some real world Data.fs from various Plone
sites I had (small ones up to some gigabyte of data) and some
handcrafted ones, there doesn't seem to be any performance difference
and an average 1% size reduction. Obviously this is highly dependent on
the data as version 2 only gives advantages in the way the object
metadata is stored but not the payload of the object, data.fs files with
a high number of small new-style class based objects might see some
bigger improvements.

Now without using the highly debatable 'extension registry' mentioned in
http://www.python.org/dev/peps/pep-0307 this doesn't seem to be much a
gain, though.

If others want to play with the branch feel free to do so. Unless
someone can convince me of the real value in pursuing this I'll abandon
the branch.


P.S. For the last thread on this issue see

For more information about ZODB, see the ZODB Wiki:

ZODB-Dev mailing list  -  ZODB-Dev@zope.org

Reply via email to