imagecache

package
v0.1.20 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2018 License: MPL-2.0 Imports: 22 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package imagecache handles loading and caching of docker images.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ImageCache

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

ImageCache wraps caching.Cache such that we don't need to do any casting inside the engine and sandbox implementations

func New

func New(d *docker.Client, tracker gc.ResourceTracker, monitor runtime.Monitor) *ImageCache

New creates a new ImageCache object

func (*ImageCache) ImageSchema

func (ic *ImageCache) ImageSchema() schematypes.Schema

ImageSchema returns the JSON schema by which images can be specified when ImageCache.Require is called

func (*ImageCache) Require

func (ic *ImageCache) Require(ctx *runtime.TaskContext, imagePayload interface{}) (*ImageHandle, error)

Require that an image is loaded or returned from cache. The imagePayload given must satisfy ImageCache.ImageSchema()

type ImageHandle

type ImageHandle struct {
	*caching.Handle
	ImageName string
}

ImageHandle wraps caching.Handle such that we don't need to do any casting to access the ImageName

Jump to

Keyboard shortcuts

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