mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
ImageService: rename GraphDriverName to StorageDriver
Make the function name more generic, as it's no longer used only for graphdrivers but also for snapshotters. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
parent
031c731c68
commit
8dd14509d7
4 changed files with 7 additions and 10 deletions
|
@ -154,7 +154,7 @@ func (daemon *Daemon) newContainer(name string, operatingSystem string, config *
|
||||||
base.ImageID = imgID
|
base.ImageID = imgID
|
||||||
base.NetworkSettings = &network.Settings{IsAnonymousEndpoint: noExplicitName}
|
base.NetworkSettings = &network.Settings{IsAnonymousEndpoint: noExplicitName}
|
||||||
base.Name = name
|
base.Name = name
|
||||||
base.Driver = daemon.imageService.GraphDriverName()
|
base.Driver = daemon.imageService.StorageDriver()
|
||||||
base.OS = operatingSystem
|
base.OS = operatingSystem
|
||||||
return base, err
|
return base, err
|
||||||
}
|
}
|
||||||
|
|
|
@ -78,10 +78,9 @@ func (i *ImageService) Cleanup() error {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// GraphDriverName returns the name of the graph drvier
|
// StorageDriver returns the name of the default storage-driver (snapshotter)
|
||||||
// moved from Daemon.GraphDriverName, used by:
|
// used by the ImageService.
|
||||||
// - newContainer
|
func (i *ImageService) StorageDriver() string {
|
||||||
func (i *ImageService) GraphDriverName() string {
|
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -72,6 +72,6 @@ type ImageService interface {
|
||||||
DistributionServices() images.DistributionServices
|
DistributionServices() images.DistributionServices
|
||||||
Children(id image.ID) []image.ID
|
Children(id image.ID) []image.ID
|
||||||
Cleanup() error
|
Cleanup() error
|
||||||
GraphDriverName() string
|
StorageDriver() string
|
||||||
UpdateConfig(maxDownloads, maxUploads int)
|
UpdateConfig(maxDownloads, maxUploads int)
|
||||||
}
|
}
|
||||||
|
|
|
@ -172,10 +172,8 @@ func (i *ImageService) Cleanup() error {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// GraphDriverName returns the name of the graph drvier
|
// StorageDriver returns the name of the storage driver used by the ImageService.
|
||||||
// moved from Daemon.GraphDriverName, used by:
|
func (i *ImageService) StorageDriver() string {
|
||||||
// - newContainer
|
|
||||||
func (i *ImageService) GraphDriverName() string {
|
|
||||||
return i.layerStore.DriverName()
|
return i.layerStore.DriverName()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue