bucket

package
v0.0.0-...-5a5b885 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

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

Service is a structure used for bucket operations on S3

func NewService

func NewService(s3Client *s3.S3) *Service

NewService creates a Service and returns it.

func (Service) BucketExists

func (s Service) BucketExists(ctx aws.Context, bucket *string) bool

BucketExists returns true if a bucket exists and the S3Client has permission to access it, false otherwise.

func (Service) CreateBucket

func (s Service) CreateBucket(ctx aws.Context, bucket *string) (bool, error)

CreateBucket creates a bucket with the given bucket name and returns true or false if it's created or not, returns an error if it didn't.

func (Service) NormalizeCephBucketName

func (s Service) NormalizeCephBucketName(bucketName string) string

NormalizeCephBucketName gets a bucket name and normalizes it according to ceph s3's constraints.

Jump to

Keyboard shortcuts

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