Commit f2653e8a authored by Jim Fulton's avatar Jim Fulton

Bugs fixed

----------

- Shutting down a process while committing a transaction could cause
  ZEO client caches to have invalid data.  This, in turn caused stale
  data to remain in the cache until it was updated.
parent df3263e5
......@@ -2,6 +2,16 @@
Change History
================
3.10.0b5 (2010-09-??)
=====================
Bugs fixed
----------
- Shutting down a process while committing a transaction could cause
ZEO client caches to have invalid data. This, in turn caused stale
data to remain in the cache until it was updated.
3.10.0b4 (2010-07-19)
=====================
......
......@@ -1237,6 +1237,7 @@ class ClientStorage(object):
if had_blobs:
self._check_blob_size(self._blob_data_bytes_loaded)
self._cache.setLastTid(tid)
self._tbuf.clear()
def undo(self, trans_id, txn):
......@@ -1362,6 +1363,11 @@ class ClientStorage(object):
self.finish_verification(pair)
return "quick verification"
elif ltid and ltid != utils.z64:
# XXX Hm, to have gotten here, the cache is non-empty, but
# it has no last tid. This doesn't seem like good situation.
# We shouldn't treat it so lightly.
self._cache.setLastTid(ltid)
zope.event.notify(ZEO.interfaces.StaleCache(self))
......
......@@ -676,7 +676,9 @@ class ClientCache(object):
if ofs is None:
# 0x10 == invalidate (miss)
self._trace(0x10, oid, tid)
return self.setLastTid(tid)
if server_invalidation:
self.setLastTid(tid)
return
self.f.seek(ofs)
read = self.f.read
......@@ -702,7 +704,8 @@ class ClientCache(object):
# 0x1C = invalidate (hit, saving non-current)
self._trace(0x1C, oid, tid)
return self.setLastTid(tid)
if server_invalidation:
self.setLastTid(tid)
##
# Generates (oid, serial) oairs for all objects in the
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment