[Zodb-checkins] CVS: ZODB3/ZODB - Connection.py:1.98.6.6

Jeremy Hylton jeremy at zope.com
Mon Jul 7 15:15:44 EDT 2003


Update of /cvs-repository/ZODB3/ZODB
In directory cvs.zope.org:/tmp/cvs-serv26493

Modified Files:
      Tag: zodb33-devel-branch
	Connection.py 
Log Message:
Repair _resetCache().


=== ZODB3/ZODB/Connection.py 1.98.6.5 => 1.98.6.6 ===
--- ZODB3/ZODB/Connection.py:1.98.6.5	Mon Jul  7 14:11:21 2003
+++ ZODB3/ZODB/Connection.py	Mon Jul  7 14:15:38 2003
@@ -226,14 +226,11 @@
         return self
 
     def _resetCache(self):
-        '''
-        Creates a new cache, discarding the old.
-        '''
+        """Creates a new cache, discarding the old."""
         self._code_timestamp = global_code_timestamp
         self._invalidated.clear()
-        orig_cache = self._cache
-        orig_cache.clear()
-        self._cache = cache = PickleCache(self, orig_cache.cache_size)
+        cache_size = self._cache.cache_size
+        self._cache = cache = PickleCache(self, cache_size)
         self._incrgc = self.cacheGC = cache.incrgc
 
     def abort(self, object, transaction):




More information about the Zodb-checkins mailing list