Skip to content
This repository has been archived by the owner on Aug 28, 2021. It is now read-only.

Commit

Permalink
Remove references to "BUG 11" in the code since #11 has been fixed.
Browse files Browse the repository at this point in the history
  • Loading branch information
aboodman committed Jul 15, 2015
1 parent c364850 commit 0ef19f9
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 4 deletions.
1 change: 0 additions & 1 deletion datas/datastore.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ func newDataStoreInternal(cs chunks.ChunkStore, rt chunks.RootTracker, rc *rootC
if (rootRef == ref.Ref{}) {
roots = NewRootSet()
} else {
// BUG 11: This reads the entire database into memory. Whoopsie.
roots = RootSetFromVal(types.MustReadValue(rootRef, cs).(types.Set))
}
return DataStore{
Expand Down
1 change: 0 additions & 1 deletion datas/root_cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ func (cache *rootCache) Update(rootsRef ref.Ref) {
return
}

// BUG 11: This is super-inefficient with eager ReadValue and no caching
rootSet := RootSet{types.MustReadValue(rootsRef, cache.source).(types.Set)}
rootSet.Iter(func(commit Root) (stop bool) {
cache.updateFromCommit(commit)
Expand Down
2 changes: 0 additions & 2 deletions dataset/dataset.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,7 @@ func (rt *datasetRootTracker) UpdateRoot(current, last ref.Ref) bool {
return false
}

// BUG 11: Sucks to have to read the dataset root here in order to commit.
datasetRoot := types.MustReadValue(current, rt.rootStore)

rt.rootStore = mgmt.CommitDatasets(rt.rootStore, mgmt.SetDatasetRoot(mgmt.GetDatasets(rt.rootStore), rt.datasetID, datasetRoot))
return true
}

0 comments on commit 0ef19f9

Please sign in to comment.