s3

package
v1.26.3 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const Provider = "aws"

Variables

This section is empty.

Functions

func GetFileAttributes added in v1.8.0

func GetFileAttributes(ctx context.Context, params *DownloadParams, region string, slice string, transport http.RoundTripper) (*blob.Attributes, error)

func NewDownloadReader added in v1.4.0

func NewDownloadReader(ctx context.Context, params *DownloadParams, region string, slice string, transport http.RoundTripper) (*blob.Reader, error)

func NewSliceURL

func NewSliceURL(params *UploadParams, slice string) string

func NewUploadWriter

func NewUploadWriter(ctx context.Context, params *UploadParams, region string, slice string, transport http.RoundTripper) (*blob.Writer, error)

Types

type Credentials

type Credentials struct {
	AccessKeyID     string       `json:"AccessKeyId"`
	SecretAccessKey string       `json:"SecretAccessKey"`
	SessionToken    string       `json:"SessionToken"`
	Expiration      iso8601.Time `json:"Expiration"`
}

type DownloadParams added in v1.4.0

type DownloadParams struct {
	Credentials Credentials `json:"credentials"`
	Path        Path        `json:"s3Path"`
}

func (*DownloadParams) DestinationURL added in v1.6.0

func (p *DownloadParams) DestinationURL() (string, error)

type Path added in v1.4.0

type Path struct {
	Key    string `json:"key"`
	Bucket string `json:"bucket"`
}

type UploadParams

type UploadParams struct {
	Path
	Credentials Credentials                  `json:"credentials"`
	ACL         s3types.ObjectCannedACL      `json:"acl"`
	Encryption  s3types.ServerSideEncryption `json:"x-amz-server-side-encryption"`
}

Jump to

Keyboard shortcuts

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