filestore

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2019 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrCheckBucketExists could not verify that bucket directory exists
	ErrCheckBucketExists = &shared.BadRequestError{Message: "could not verify that bucket directory exists"}
	// ErrWriteFile could not write file
	ErrWriteFile = &shared.BadRequestError{Message: "could not write file"}
	// ErrReadFile could not read file
	ErrReadFile = &shared.BadRequestError{Message: "could not read file"}
	// ErrCheckFileExists could not check if file exists
	ErrCheckFileExists = &shared.BadRequestError{Message: "could not check if file exists"}
	// ErrDeleteFile could not delete file
	ErrDeleteFile = &shared.BadRequestError{Message: "could not delete file"}
	// ErrListFiles could not list files
	ErrListFiles = &shared.BadRequestError{Message: "could not list files"}
	// ErrBucketConfigDeserialization bucket config could not be deserialized
	ErrBucketConfigDeserialization = &shared.BadRequestError{Message: "bucket config could not be deserialized"}
)

Functions

func NewClient

func NewClient(cfg *Config) (blobstore.Client, error)

NewClient returns a new Client backed by file system

Types

type Config

type Config struct {
	StoreDirectory string   `yaml:"storeDirectory"`
	DefaultBucket  string   `yaml:"defaultBucket"`
	CustomBuckets  []string `yaml:"customBuckets"`
}

Config describes the configuration needed to construct a blobstore client backed by file system

func (*Config) Validate

func (c *Config) Validate() error

Validate validates config

Jump to

Keyboard shortcuts

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