Skip to content

Commit

Permalink
Remove writing into redundant cache in build-index (#155)
Browse files Browse the repository at this point in the history
Since there is the cache on Nginx side, there is no point to writing
tag info into another cache after pulling from any backend.

Removed calling to writeTagToDisk in resolveFromBackend function.
  • Loading branch information
EltonzHu authored and codygibb committed May 13, 2019
1 parent 4213e71 commit 403ee87
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions build-index/tagstore/store.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ import (
"github.com/uber/kraken/lib/persistedretry/writeback"
"github.com/uber/kraken/lib/store"
"github.com/uber/kraken/lib/store/metadata"
"github.com/uber/kraken/utils/log"

"github.com/uber-go/tally"
)
Expand Down Expand Up @@ -160,8 +159,5 @@ func (s *tagStore) resolveFromBackend(tag string) (core.Digest, error) {
if err != nil {
return core.Digest{}, fmt.Errorf("parse backend digest: %s", err)
}
if err := s.writeTagToDisk(tag, d); err != nil {
log.With("tag", tag).Errorf("Error writing tag to disk: %s", err)
}
return d, nil
}

0 comments on commit 403ee87

Please sign in to comment.