cache

package
v0.16.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 7, 2023 License: Apache-2.0 Imports: 18 Imported by: 2

Documentation

Index

Constants

View Source
const MetadataLabel = "io.buildpacks.lifecycle.cache.metadata"

Variables

This section is empty.

Functions

func NewCachingImage

func NewCachingImage(image imgutil.Image, cache *VolumeCache) imgutil.Image

Types

type CachingImage added in v0.14.1

type CachingImage struct {
	imgutil.Image
	// contains filtered or unexported fields
}

func (*CachingImage) AddLayer added in v0.14.1

func (c *CachingImage) AddLayer(path string) error

func (*CachingImage) AddLayerWithDiffID added in v0.14.1

func (c *CachingImage) AddLayerWithDiffID(path string, diffID string) error

func (*CachingImage) GetLayer added in v0.14.1

func (c *CachingImage) GetLayer(diffID string) (io.ReadCloser, error)

func (*CachingImage) ReuseLayer added in v0.14.1

func (c *CachingImage) ReuseLayer(diffID string) error

func (*CachingImage) Save added in v0.14.1

func (c *CachingImage) Save(additionalNames ...string) error

func (*CachingImage) SaveAs added in v0.16.0

func (c *CachingImage) SaveAs(name string, additionalNames ...string) error

type ImageCache

type ImageCache struct {
	// contains filtered or unexported fields
}

func NewImageCache

func NewImageCache(origImage imgutil.Image, newImage imgutil.Image, logger log.Logger) *ImageCache

func NewImageCacheFromName

func NewImageCacheFromName(name string, keychain authn.Keychain, logger log.Logger) (*ImageCache, error)

func (*ImageCache) AddLayerFile

func (c *ImageCache) AddLayerFile(tarPath string, diffID string) error

func (*ImageCache) Commit

func (c *ImageCache) Commit() error

func (*ImageCache) DeleteOrigImage added in v0.8.1

func (c *ImageCache) DeleteOrigImage() error

func (*ImageCache) Exists added in v0.10.0

func (c *ImageCache) Exists() bool

func (*ImageCache) Name

func (c *ImageCache) Name() string

func (*ImageCache) RetrieveLayer

func (c *ImageCache) RetrieveLayer(diffID string) (io.ReadCloser, error)

func (*ImageCache) RetrieveMetadata

func (c *ImageCache) RetrieveMetadata() (platform.CacheMetadata, error)

func (*ImageCache) ReuseLayer

func (c *ImageCache) ReuseLayer(diffID string) error

func (*ImageCache) SetMetadata

func (c *ImageCache) SetMetadata(metadata platform.CacheMetadata) error

type VolumeCache

type VolumeCache struct {
	// contains filtered or unexported fields
}

func NewVolumeCache

func NewVolumeCache(dir string) (*VolumeCache, error)

func (*VolumeCache) AddLayer

func (c *VolumeCache) AddLayer(rc io.ReadCloser, diffID string) error

func (*VolumeCache) AddLayerFile

func (c *VolumeCache) AddLayerFile(tarPath string, diffID string) error

func (*VolumeCache) Commit

func (c *VolumeCache) Commit() error

func (*VolumeCache) Exists added in v0.10.0

func (c *VolumeCache) Exists() bool

func (*VolumeCache) HasLayer

func (c *VolumeCache) HasLayer(diffID string) (bool, error)

func (*VolumeCache) Name

func (c *VolumeCache) Name() string

func (*VolumeCache) RetrieveLayer

func (c *VolumeCache) RetrieveLayer(diffID string) (io.ReadCloser, error)

func (*VolumeCache) RetrieveLayerFile

func (c *VolumeCache) RetrieveLayerFile(diffID string) (string, error)

func (*VolumeCache) RetrieveMetadata

func (c *VolumeCache) RetrieveMetadata() (platform.CacheMetadata, error)

func (*VolumeCache) ReuseLayer

func (c *VolumeCache) ReuseLayer(diffID string) error

func (*VolumeCache) SetMetadata

func (c *VolumeCache) SetMetadata(metadata platform.CacheMetadata) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL