Commit 559dc9bf authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent d0ecdf0b
......@@ -1828,7 +1828,8 @@ func (head *Head) bigopen(ctx context.Context, oid zodb.Oid) (_ *BigFile, err er
head.bfdir.δFtail.Track(f, -1, sizePath, nil)
head.bfdir.δFmu.Unlock()
// f.δtail = NewΔTailI64(zconn.At())
// FIXME: scan zfile.blktab - so that we can detect all btree changes
// see "XXX building δFtail lazily ..." in notes.txt
}
return f, nil
......
......@@ -296,6 +296,16 @@ class tDB:
return "@at%d (%s)" % (i, h(at))
# zfiles returns ZBigFiles that were ever changed under t.
def zfiles(t):
zfs = set()
for dF in t.dFtail:
for zf in dF.byfile:
if zf not in zfs:
zfs.add(zf)
return zfs
# tFile provides testing environment for one bigfile on wcfs.
#
......@@ -702,7 +712,7 @@ def test_wcfs():
# checkSetupWatch verifies setting up new watch for zf@at.
def checkSetupWatch(zf, at):
print('C: check setup watch f<%s> %s' % (h(zf._p_oid), t.hat(at)))
print('\nC: check setup watch f<%s> %s' % (h(zf._p_oid), t.hat(at)))
# all changes to zf
vdf = [_.byfile[zf] for _ in t.dFtail if zf in _.byfile]
......@@ -744,9 +754,8 @@ def test_wcfs():
wg.wait()
# XXX for zf: check all revisions, even if zf was not changed in rev
for zf in t.zfiles():
for dF in t.dFtail:
for zf in dF.byfile:
checkSetupWatch(zf, dF.rev)
......
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