s3

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Nov 5, 2025 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(s3c aws.S3ObjectClient, bucket string, opts ...Options) (store.Store, error)

Types

type Options

type Options func(*Store) error

func WithKeyPrefix

func WithKeyPrefix(prefix string) Options

WithKeyPrefix sets the key prefix for the store.

type Store

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

Store is a store that uses S3 as the underlying storage.

func (*Store) Copy

func (s *Store) Copy(ctx context.Context, srcKey, dstKey string) error

Copy copies an object from one key to another

func (*Store) Delete

func (s *Store) Delete(ctx context.Context, key string) error

func (*Store) Load

func (s *Store) Load(ctx context.Context, key string) (io.ReadCloser, *store.Headers, error)

Load loads the data from the S3 bucket It is the responsibility of the caller to close the returned reader

func (*Store) Store

func (s *Store) Store(ctx context.Context, key string, reader io.Reader, headers *store.Headers) error

Store stores the data in the S3 bucket

Jump to

Keyboard shortcuts

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