miniostorage

package
v0.0.0-...-ae6cc27 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2018 License: BSD-3-Clause Imports: 4 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MinioStorage

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

MinioStorage implements the strata.Storage interface using minio as its storage backing

func NewMinioStorage

func NewMinioStorage(endPoint, accessKeyID, secretAccessKey, bucket, prefix, region string, secure bool) (*MinioStorage, error)

NewMinioStorage initializes the MinioStorage with Minio arguments

func (*MinioStorage) Delete

func (m *MinioStorage) Delete(name string) error

Delete removes the object from the minio bucket

func (*MinioStorage) Get

func (m *MinioStorage) Get(name string) (io.ReadCloser, error)

Get returns a reader to the specified minio object.

func (*MinioStorage) List

func (m *MinioStorage) List(prefix string, maxSize int) ([]string, error)

List returns a list of objects

func (*MinioStorage) Lock

func (m *MinioStorage) Lock(path string) error

Lock is not implemented

func (*MinioStorage) Put

func (m *MinioStorage) Put(name string, data []byte) error

Put places the byte slice with the given objectName in the minio bucket

func (*MinioStorage) PutReader

func (m *MinioStorage) PutReader(name string, reader io.Reader) error

PutReader consumes the given reader and stores it with the specified name in the minio bucket.

func (*MinioStorage) Unlock

func (m *MinioStorage) Unlock(path string) error

Unlock is not implemented

Jump to

Keyboard shortcuts

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