Use pickle protocol 2.

This way, pickling gets %50 faster and takes %5 less space, unpickling gets about %30 faster
This commit is contained in:
Mehmet D. Akın
2007-03-05 10:19:23 +00:00
parent 8ad8b4c01e
commit 14cbd349c8
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -12,9 +12,9 @@
# PiSi version
__version__ = "1.1"
__version__ = "1.1_20070305"
__dbversion__ = "1.1_rc7"
__dbversion__ = "1.1_20070305"
__filesdbversion__ = "1.0.5" # yes, this is the real bottleneck
__all__ = [ 'api', 'config', 'packagedb', 'installdb', 'search' ]
+1 -1
View File
@@ -95,7 +95,7 @@ class DBShelf:
raise CodingError()
def encode(self, obj):
return cPickle.dumps(obj, 1)
return cPickle.dumps(obj, 2)
def clear(self, txn = None):
def proc(txn):