You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Refactor API to split functionality into mutable and immutable interfaces. This will enable read only snapshots to previously stored versions, (fixing #68, see also #87). With these changes, it will be possible to load read-only snapshots at previous versions on demand, and only load mutable trees at the most recently saved tree. This should speed up load times for trees with many versions, as we are currently loading each root into memory, which takes a linear number of database calls.
Steps:
Replace Tree with ImmutableTree
Merge VersionedTree and orphaningTree into MutableTree
Move mutable methods on Tree into MutableTree
Move recursive mutation methods on Node into MutableTree
Move recursive lookup methods on Node into ImmutableTree
High level overview of resulting interfaces:
MutableTree
tree *ImmutableTree
Load()
Set(key, value)
Remove(key)
Commit()
Rollback()
GetImmutable(version)
DeleteImmutable(version)
ImmutableTree
root *Node
Has(key)
Get(key)
GetWithProof(key)
GetByIndex(index)
IterateRange(start, end)
GetRangeWithProof(start, end)
Hash()
Size()
Version()
Node
isLeaf()
hash()
getLeftNode()
getRightNode()
The text was updated successfully, but these errors were encountered:
Refactor API to split functionality into mutable and immutable interfaces. This will enable read only snapshots to previously stored versions, (fixing #68, see also #87). With these changes, it will be possible to load read-only snapshots at previous versions on demand, and only load mutable trees at the most recently saved tree. This should speed up load times for trees with many versions, as we are currently loading each root into memory, which takes a linear number of database calls.
Steps:
High level overview of resulting interfaces:
MutableTree
ImmutableTree
Node
The text was updated successfully, but these errors were encountered: