blobstore

package
v0.0.6 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2015 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlobManager

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

func NewBlobManager

func NewBlobManager(fs boshsys.FileSystem, dirProvider boshdir.Provider) (manager BlobManager)

func (BlobManager) Fetch

func (manager BlobManager) Fetch(blobID string) (blobBytes []byte, err error)

func (BlobManager) Write

func (manager BlobManager) Write(blobID string, blobBytes []byte) (err error)

type Blobstore

type Blobstore interface {
	// Assuming that local file system is available,
	// file handle is returned to downloaded blob.
	// Caller must not assume anything about layout of such scratch space.
	// Cleanup call is needed to properly cleanup downloaded blob.
	Get(blobID, fingerprint string) (fileName string, err error)

	CleanUp(fileName string) (err error)

	Create(fileName string) (blobID string, fingerprint string, err error)

	Validate() (err error)
}

func NewExternalBlobstore

func NewExternalBlobstore(
	provider string,
	options map[string]interface{},
	fs boshsys.FileSystem,
	runner boshsys.CmdRunner,
	uuidGen boshuuid.Generator,
	configFilePath string,
) Blobstore

func NewLocalBlobstore

func NewLocalBlobstore(
	fs boshsys.FileSystem,
	uuidGen boshuuid.Generator,
	options map[string]interface{},
) Blobstore

func NewRetryableBlobstore

func NewRetryableBlobstore(blobstore Blobstore, maxTries int, logger boshlog.Logger) Blobstore

func NewSHA1VerifiableBlobstore

func NewSHA1VerifiableBlobstore(blobstore Blobstore) Blobstore

type Provider

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

func NewProvider

func NewProvider(
	platform boshplatform.Platform,
	dirProvider boshdir.Provider,
	logger boshlog.Logger,
) (p Provider)

func (Provider) Get

func (p Provider) Get(settings boshsettings.Blobstore) (blobstore Blobstore, err error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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