mirror of
https://github.com/moby/moby.git
synced 2026-08-04 23:21:00 +00:00
c8d/progress: Remove unused mountable
It's no longer needed as we get this information from containerd directly. Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
This commit is contained in:
@@ -120,9 +120,6 @@ func (i *ImageService) pushRef(ctx context.Context, targetRef reference.Named, m
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
for dgst := range mountableBlobs {
|
||||
pp.addMountable(dgst)
|
||||
}
|
||||
|
||||
// Create a store which fakes the local existence of possibly mountable blobs.
|
||||
// Otherwise they can't be pushed at all.
|
||||
|
||||
@@ -171,30 +171,7 @@ func (p pullProgress) UpdateProgress(ctx context.Context, ongoing *jobs, out pro
|
||||
}
|
||||
|
||||
type pushProgress struct {
|
||||
Tracker docker.StatusTracker
|
||||
mountable map[digest.Digest]struct{}
|
||||
mutex sync.Mutex
|
||||
}
|
||||
|
||||
func (p *pushProgress) addMountable(dgst digest.Digest) {
|
||||
p.mutex.Lock()
|
||||
defer p.mutex.Unlock()
|
||||
|
||||
if p.mountable == nil {
|
||||
p.mountable = map[digest.Digest]struct{}{}
|
||||
}
|
||||
p.mountable[dgst] = struct{}{}
|
||||
}
|
||||
|
||||
func (p *pushProgress) isMountable(dgst digest.Digest) bool {
|
||||
p.mutex.Lock()
|
||||
defer p.mutex.Unlock()
|
||||
|
||||
if p.mountable == nil {
|
||||
return false
|
||||
}
|
||||
_, has := p.mountable[dgst]
|
||||
return has
|
||||
Tracker docker.StatusTracker
|
||||
}
|
||||
|
||||
func (p *pushProgress) UpdateProgress(ctx context.Context, ongoing *jobs, out progress.Output, start time.Time) error {
|
||||
|
||||
Reference in New Issue
Block a user