Commit 016bd9be authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent b984e690
...@@ -28,7 +28,7 @@ package zdata ...@@ -28,7 +28,7 @@ package zdata
// //
// ΔFtail organization // ΔFtail organization
// //
// ΔFtail leverages // ΔFtail leverages:
// //
// - ΔBtail to track changes to ZBigFile.blktab BTree, and // - ΔBtail to track changes to ZBigFile.blktab BTree, and
// - ΔZtail to track changes to ZBlk objects and to ZBigFile object itself. // - ΔZtail to track changes to ZBlk objects and to ZBigFile object itself.
...@@ -42,7 +42,7 @@ package zdata ...@@ -42,7 +42,7 @@ package zdata
// and handles complexity of recomputing vδB when set of tracked blocks // and handles complexity of recomputing vδB when set of tracked blocks
// changes. // changes.
// //
// Changes to ZBigFile object indicate epochs. Epochs could be // Changes to ZBigFile object indicate epochs. Epochs could be:
// //
// - file creation or deletion, // - file creation or deletion,
// - change of ZBigFile.blksize, // - change of ZBigFile.blksize,
...@@ -604,6 +604,11 @@ func (δFtail *ΔFtail) SliceByFileRev(zfile *ZBigFile, lo, hi zodb.Tid) /*reado ...@@ -604,6 +604,11 @@ func (δFtail *ΔFtail) SliceByFileRev(zfile *ZBigFile, lo, hi zodb.Tid) /*reado
// δFile ────────o───────o──────x─────x──────────────────────── // δFile ────────o───────o──────x─────x────────────────────────
δftail, err := δFtail.rebuildIfNeeded(zfile.POid())
if err != nil {
panic(err) // XXX
}
var vδf []*ΔFile var vδf []*ΔFile
// vδfTail returns or creates vδf entry for revision tail // vδfTail returns or creates vδf entry for revision tail
// tail must be <= all vδf revisions // tail must be <= all vδf revisions
...@@ -623,11 +628,6 @@ func (δFtail *ΔFtail) SliceByFileRev(zfile *ZBigFile, lo, hi zodb.Tid) /*reado ...@@ -623,11 +628,6 @@ func (δFtail *ΔFtail) SliceByFileRev(zfile *ZBigFile, lo, hi zodb.Tid) /*reado
return δfTail return δfTail
} }
δftail, err := δFtail.rebuildIfNeeded(zfile.POid())
if err != nil {
panic(err) // XXX
}
vδZ := δFtail.δBtail.ΔZtail().SliceByRev(lo, hi) vδZ := δFtail.δBtail.ΔZtail().SliceByRev(lo, hi)
iz := len(vδZ) - 1 iz := len(vδZ) - 1
......
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