sendfile

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2022 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UploadTargetsWithRetry

func UploadTargetsWithRetry(targets []string, data []byte, dstFileName string, retryInterval time.Duration, retryTimeout time.Duration) error

func UploadWatcher

func UploadWatcher(watchdir string, targets []string, retryInterval time.Duration, retryTimeout time.Duration, forever bool) (error, chan bool)

func UploadWithRetry

func UploadWithRetry(target Target, data []byte, retryInterval time.Duration, retryTimeout time.Duration) error

func UsageInfo

func UsageInfo() string

func ValidateTargetUrl

func ValidateTargetUrl(targetUrl string) error

Types

type CreateUploader

type CreateUploader func() Target

type Target

type Target interface {
	Export(data []byte) error
	SetUploadUrl(url string) error
	SetDestName(name string) error

	UsageInfo() string
	Scheme() string
}

func NewUploader

func NewUploader(targetUrl string) (Target, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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