s3resup

package module
v0.0.0-...-469f385 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2021 License: MIT Imports: 6 Imported by: 0

README

s3resup

S3 Resumable Uploads Library

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Uploader

type Uploader struct {
	S3          s3iface.S3API
	Concurrency int
	PartSize    int64
}

Uploader stores configurations for uploading

func NewUploader

func NewUploader(c client.ConfigProvider, options ...func(*Uploader)) *Uploader

NewUploader creates an uploader

func (*Uploader) Upload

func (u *Uploader) Upload(reader io.Reader, input s3.PutObjectInput) error

Upload uploads the contents of reader to the s3 location specified by input. The upload is multi-part and will resume, preserving it's progress if the upload is interrupted for any reason.

func (*Uploader) UploadFile

func (u *Uploader) UploadFile(name string, input s3.PutObjectInput) error

UploadFile uploads the contents of a file to the s3 location specified by input. The upload is multi-part and will resume, preserving it's progress if the upload is interrupted for any reason.

Jump to

Keyboard shortcuts

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