diff options
author | Luke Shumaker <lukeshu@lukeshu.com> | 2023-03-29 10:00:18 -0600 |
---|---|---|
committer | Luke Shumaker <lukeshu@lukeshu.com> | 2023-03-30 10:03:50 -0600 |
commit | 94aa0ec3e9f7145cdf177ad6f6d3d8b7d5bdbef7 (patch) | |
tree | 2e0bafd99a433d7271bf42e68ab1b5c1eba99e2b /lib/btrfsutil/rebuilt_forrest.go | |
parent | 2eb7033431866cb05d235eb10c280a4810bf88a7 (diff) |
btrfstree: Change the NodeSource API so that it can do caching
Diffstat (limited to 'lib/btrfsutil/rebuilt_forrest.go')
-rw-r--r-- | lib/btrfsutil/rebuilt_forrest.go | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/lib/btrfsutil/rebuilt_forrest.go b/lib/btrfsutil/rebuilt_forrest.go index 4f7a24b..60f3010 100644 --- a/lib/btrfsutil/rebuilt_forrest.go +++ b/lib/btrfsutil/rebuilt_forrest.go @@ -141,8 +141,6 @@ type RebuiltForrest struct { leafs containers.Cache[btrfsprim.ObjID, map[btrfsvol.LogicalAddr]containers.Set[btrfsvol.LogicalAddr]] incItems containers.Cache[btrfsprim.ObjID, itemIndex] excItems containers.Cache[btrfsprim.ObjID, itemIndex] - - nodes containers.Cache[btrfsvol.LogicalAddr, btrfstree.Node] } // NewRebuiltForrest returns a new RebuiltForrest instance. The @@ -170,9 +168,6 @@ func NewRebuiltForrest(file btrfstree.NodeSource, sb btrfstree.Superblock, graph containers.SourceFunc[btrfsprim.ObjID, itemIndex](func(ctx context.Context, treeID btrfsprim.ObjID, excItems *itemIndex) { *excItems = ret.trees[treeID].uncachedExcItems(ctx) })) - ret.nodes = containers.NewARCache[btrfsvol.LogicalAddr, btrfstree.Node](textui.Tunable(8), - containers.SourceFunc[btrfsvol.LogicalAddr, btrfstree.Node](ret.readNode)) - if ret.cb == nil { ret.cb = noopRebuiltForrestCallbacks{ forrest: ret, |