Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Storage ¶
type Storage interface { DeleteObjectsWithPrefix(ctx context.Context, container, prefix string) error CreateContainerIfNotExists(ctx context.Context, container string) error DeleteContainerIfExists(ctx context.Context, container string) error }
Storage represents a Openstack swift storage client.
type StorageClient ¶
type StorageClient struct {
// contains filtered or unexported fields
}
StorageClient represents a Azure storage client.
func NewStorageClientFromSecretRef ¶
func NewStorageClientFromSecretRef(ctx context.Context, c client.Client, secretRef corev1.SecretReference, region string) (*StorageClient, error)
NewStorageClientFromSecretRef retrieves the openstack client from specified by the secret reference.
func (*StorageClient) CreateContainerIfNotExists ¶
func (s *StorageClient) CreateContainerIfNotExists(ctx context.Context, container string) error
CreateContainerIfNotExists creates the openstack blob container with name <container>. If it already exist, no error is returned.
func (*StorageClient) DeleteContainerIfExists ¶
func (s *StorageClient) DeleteContainerIfExists(ctx context.Context, container string) error
DeleteContainerIfExists deletes the openstack blob container with name <container>. If it does not exist, no error is returned.
func (*StorageClient) DeleteObjectsWithPrefix ¶
func (s *StorageClient) DeleteObjectsWithPrefix(ctx context.Context, container, prefix string) error
DeleteObjectsWithPrefix deletes the blob objects with the specific <prefix> from <container>. If it does not exist, no error is returned.
Click to show internal directories.
Click to hide internal directories.