Documentation
¶
Index ¶
- Variables
- type GCSOptions
- type Google
- func (g *Google) Delete(ctx context.Context, key string) error
- func (g *Google) Get(ctx context.Context, name string) (*Object, error)
- func (g *Google) List(ctx context.Context, prefix string) ([]*Object, error)
- func (g *Google) Name() string
- func (g *Google) Put(ctx context.Context, name string, data []byte) error
- func (g *Google) PutReader(ctx context.Context, name string, data io.Reader) error
- type MinIO
- func (m *MinIO) Close()
- func (m *MinIO) Delete(ctx context.Context, name string) error
- func (m *MinIO) Get(ctx context.Context, name string) (*Object, error)
- func (m *MinIO) List(ctx context.Context, prefix string) ([]*Object, error)
- func (m *MinIO) ListRecursive(ctx context.Context, prefix string, recursive bool) ([]minio.ObjectInfo, error)
- func (m *MinIO) Name() string
- func (m *MinIO) Put(ctx context.Context, name string, data []byte) error
- func (m *MinIO) PutReader(ctx context.Context, name string, r io.Reader) error
- type MinIOOptions
- type Mock
- func (m *Mock) AddTree(name string, data []byte)
- func (m *Mock) Delete(_ context.Context, name string) error
- func (m *Mock) Get(_ context.Context, name string) (*Object, error)
- func (m *Mock) List(_ context.Context, prefix string) ([]*Object, error)
- func (m *Mock) Name() string
- func (m *Mock) Put(_ context.Context, name string, data []byte) error
- func (m *Mock) PutReader(ctx context.Context, name string, data io.Reader) error
- type Object
- type S3
- func (s *S3) Delete(ctx context.Context, name string) error
- func (s *S3) Endpoint() string
- func (s *S3) ExistBucket(ctx context.Context, name string) bool
- func (s *S3) ExistObject(ctx context.Context, key string) bool
- func (s *S3) Get(ctx context.Context, name string) (*Object, error)
- func (s *S3) List(ctx context.Context, prefix string) ([]*Object, error)
- func (s *S3) ListIter(ctx context.Context, prefix string) (iter.Seq[*Object], error)
- func (s *S3) MakeBucket(ctx context.Context, name string) error
- func (s *S3) Name() string
- func (s *S3) Put(ctx context.Context, name string, data []byte) error
- func (s *S3) PutReader(ctx context.Context, name string, r io.Reader) error
- type S3Options
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrObjectNotFound = xerrors.New("storage: object not found")
)
Functions ¶
This section is empty.
Types ¶
type GCSOptions ¶
type GCSOptions struct {
Retries int
}
type MinIO ¶
type MinIO struct {
// contains filtered or unexported fields
}
func NewMinIOStorage ¶
func NewMinIOStorage(bucket string, opt MinIOOptions) *MinIO
NewMinIOStorage returns the client for MinIO Deprecated: Use the client for S3 instead. The SDK of MinIO is not good quality.
func (*MinIO) ListRecursive ¶
type MinIOOptions ¶
type MinIOOptions struct { Name string Namespace string Endpoint string Region string Port int AccessKey string SecretAccessKey string Retries int Dev bool // PodLister is an optional value. PodLister corev1listers.PodLister // ServiceLister is an optional value. ServiceLister corev1listers.ServiceLister // Transport is an optional value. Transport http.RoundTripper // contains filtered or unexported fields }
func NewMinIOOptionsViaEndpoint ¶
func NewMinIOOptionsViaEndpoint(endpoint, region, accessKey, secretAccessKey string) MinIOOptions
func NewMinIOOptionsViaService ¶
func NewMinIOOptionsViaService( client kubernetes.Interface, config *rest.Config, name, namespace string, port int, accessKey, secretAccessKey string, dev bool, ) MinIOOptions
func (*MinIOOptions) Client ¶
func (m *MinIOOptions) Client(ctx context.Context) (*minio.Client, error)
func (*MinIOOptions) Close ¶
func (m *MinIOOptions) Close()
type S3Options ¶
type S3Options struct { Region string AccessKey string SecretAccessKey string Endpoint string PathStyle bool // This is important option if you want to use with MinIO. CACertFile string PartSize uint64 Retries int // contains filtered or unexported fields }
func NewS3OptionToAWS ¶
func NewS3OptionToExternal ¶
Click to show internal directories.
Click to hide internal directories.