s3

package
v0.0.0-...-e675dcb Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Backend

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

Backend object

func NewBackend

func NewBackend(config *Config) (b *Backend, err error)

NewBackend instantiate a new OpenSwift Data Backend from configuration passed as argument

func (*Backend) AddFile

func (b *Backend) AddFile(file *common.File, fileReader io.Reader) (err error)

AddFile implementation for S3 Data Backend

func (*Backend) GetFile

func (b *Backend) GetFile(file *common.File) (reader io.ReadCloser, err error)

GetFile implementation for S3 Data Backend

func (*Backend) RemoveFile

func (b *Backend) RemoveFile(file *common.File) (err error)

RemoveFile implementation for S3 Data Backend

type BackendDetails

type BackendDetails struct {
	SSEKey string
}

BackendDetails additional backend metadata

type Config

type Config struct {
	Endpoint        string
	AccessKeyID     string
	SecretAccessKey string
	Bucket          string
	Location        string
	Prefix          string
	PartSize        uint64
	UseSSL          bool
	SSE             string
}

Config describes configuration for Swift data backend

func NewConfig

func NewConfig(params map[string]interface{}) (config *Config)

NewConfig instantiate a new default configuration and override it with configuration passed as argument

func (*Config) Validate

func (config *Config) Validate() error

Validate check config parameters

Jump to

Keyboard shortcuts

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