Documentation ¶
Index ¶
- type KeyInfo
- type S3Store
- func (s *S3Store) Connect(accessID, secretKey string, region string, endpoints ...string) (err error)
- func (s *S3Store) GetPresignedURL(bucket, key string, durations ...time.Duration) (string, error)
- func (s *S3Store) ListBucketFiles(bucket, prefix string) (prefixs []string, keys []KeyInfo, err error)
- func (s *S3Store) ListBuckets() (bkts []string, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type KeyInfo ¶
type KeyInfo struct { Key string `json:"key,omitempty"` Size int64 `json:"size,omitempty"` Stamp time.Time `json:"stamp,omitempty"` }
KeyInfo file status
type S3Store ¶
type S3Store struct {
// contains filtered or unexported fields
}
S3Store access aws s3
func (*S3Store) Connect ¶
func (s *S3Store) Connect(accessID, secretKey string, region string, endpoints ...string) (err error)
Connect connect to s3 server
func (*S3Store) GetPresignedURL ¶
GetPresignedURL creates a presigned URL for a bucket object
func (*S3Store) ListBucketFiles ¶
func (s *S3Store) ListBucketFiles(bucket, prefix string) (prefixs []string, keys []KeyInfo, err error)
ListBucketFiles Returns some or all (up to 1,000) of the objects in a bucket
func (*S3Store) ListBuckets ¶
ListBuckets Returns a list of all buckets owned
Click to show internal directories.
Click to hide internal directories.