blobstore

package
v0.22.0 Latest Latest
Warning

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

Go to latest
Published: Aug 20, 2021 License: MIT Imports: 3 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Blob

type Blob struct {
	Tags map[string]string
	Body []byte
}

Blob defines a blob which can be stored and fetched from blobstore

type Client

Client defines the interface to a blobstore client.

func NewRetryableClient added in v0.5.2

func NewRetryableClient(client Client, policy backoff.RetryPolicy) Client

NewRetryableClient constructs a blobstorre client which retries transient errors.

type DeleteRequest added in v0.13.0

type DeleteRequest struct {
	Key string
}

DeleteRequest is the request to Delete

type DeleteResponse added in v0.13.0

type DeleteResponse struct{}

DeleteResponse is the response from Delete

type ExistsRequest added in v0.13.0

type ExistsRequest struct {
	Key string
}

ExistsRequest is the request to Exists

type ExistsResponse added in v0.13.0

type ExistsResponse struct {
	Exists bool
}

ExistsResponse is the response from Exists

type GetRequest added in v0.13.0

type GetRequest struct {
	Key string
}

GetRequest is the request to Get

type GetResponse added in v0.13.0

type GetResponse struct {
	Blob Blob
}

GetResponse is the response from Get

type MockClient added in v0.13.0

type MockClient struct {
	mock.Mock
}

MockClient is an autogenerated mock type for the Client type

func (*MockClient) Delete added in v0.13.0

func (_m *MockClient) Delete(_a0 context.Context, _a1 *DeleteRequest) (*DeleteResponse, error)

Delete provides a mock function with given fields: _a0, _a1

func (*MockClient) Exists added in v0.13.0

func (_m *MockClient) Exists(_a0 context.Context, _a1 *ExistsRequest) (*ExistsResponse, error)

Exists provides a mock function with given fields: _a0, _a1

func (*MockClient) Get added in v0.13.0

func (_m *MockClient) Get(_a0 context.Context, _a1 *GetRequest) (*GetResponse, error)

Get provides a mock function with given fields: _a0, _a1

func (*MockClient) IsRetryableError added in v0.13.0

func (_m *MockClient) IsRetryableError(_a0 error) bool

func (*MockClient) Put added in v0.13.0

func (_m *MockClient) Put(_a0 context.Context, _a1 *PutRequest) (*PutResponse, error)

Put provides a mock function with given fields: _a0, _a1

type PutRequest added in v0.13.0

type PutRequest struct {
	Key  string
	Blob Blob
}

PutRequest is the request to Put

type PutResponse added in v0.13.0

type PutResponse struct{}

PutResponse is the response from Put

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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