providers

package
v0.0.0-...-c1b1270 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2024 License: Apache-2.0 Imports: 44 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckSnapshotsInProvider

func CheckSnapshotsInProvider(
	veleroCfg velerotest.VeleroConfig,
	backupName string,
	snapshotCheckPoint velerotest.SnapshotCheckPoint,
	checkStandbyCluster bool,
) error

func DeleteObjectsInBucket

func DeleteObjectsInBucket(objectStoreProvider, cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupName, subPrefix string) error

func GetBucketRegion

func GetBucketRegion(bucket string) (string, error)

GetBucketRegion returns the AWS region that a bucket is in, or an error if the region cannot be determined.

func GetVolumeInfo

func GetVolumeInfo(
	objectStoreProvider,
	cloudCredentialsFile,
	bslBucket,
	bslPrefix,
	bslConfig,
	backupName,
	subPrefix string,
) ([]*volume.BackupVolumeInfo, error)

func GetVolumeInfoMetadataContent

func GetVolumeInfoMetadataContent(
	objectStoreProvider,
	cloudCredentialsFile,
	bslBucket,
	bslPrefix,
	bslConfig,
	backupName,
	subPrefix string,
) (io.Reader, error)

func IsObjectsInBucket

func IsObjectsInBucket(objectStoreProvider, cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupName, subPrefix string) (bool, error)

func IsValidS3URLScheme

func IsValidS3URLScheme(s3URL string) bool

IsValidS3URLScheme returns true if the scheme is http:// or https:// and the url parses correctly, otherwise, return false

func ObjectsShouldBeInBucket

func ObjectsShouldBeInBucket(objectStoreProvider, cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupName, subPrefix string) error

func ObjectsShouldNotBeInBucket

func ObjectsShouldNotBeInBucket(objectStoreProvider, cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupName, subPrefix string, retryTimes int) error

Types

type AWSStorage

type AWSStorage string

func (AWSStorage) DeleteItem

func (s AWSStorage) DeleteItem(client *s3.Client, deleteObjectV2Input *s3.DeleteObjectInput) (*s3.DeleteObjectOutput, error)

func (AWSStorage) DeleteObjectsInBucket

func (s AWSStorage) DeleteObjectsInBucket(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupObject string) error

func (AWSStorage) GetMinioBucketSize

func (s AWSStorage) GetMinioBucketSize(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig string) (int64, error)

func (AWSStorage) GetObject

func (s AWSStorage) GetObject(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, objectKey string) (io.ReadCloser, error)

func (AWSStorage) IsObjectsInBucket

func (s AWSStorage) IsObjectsInBucket(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupObject string) (bool, error)

func (AWSStorage) IsSnapshotExisted

func (s AWSStorage) IsSnapshotExisted(cloudCredentialsFile, bslConfig, backupObject string, snapshotCheck test.SnapshotCheckPoint) error

func (AWSStorage) ListItems

func (s AWSStorage) ListItems(client *s3.Client, objectsV2Input *s3.ListObjectsV2Input) (*s3.ListObjectsV2Output, error)

type AzureStorage

type AzureStorage string

func (AzureStorage) DeleteObjectsInBucket

func (s AzureStorage) DeleteObjectsInBucket(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupObject string) error

func (AzureStorage) GetObject

func (s AzureStorage) GetObject(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, objectKey string) (io.ReadCloser, error)

func (AzureStorage) IsObjectsInBucket

func (s AzureStorage) IsObjectsInBucket(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupName string) (bool, error)

func (AzureStorage) IsSnapshotExisted

func (s AzureStorage) IsSnapshotExisted(cloudCredentialsFile, bslConfig, backupName string, snapshotCheck SnapshotCheckPoint) error

type GCSStorage

type GCSStorage string

func (GCSStorage) DeleteObjectsInBucket

func (s GCSStorage) DeleteObjectsInBucket(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupObject string) error

func (GCSStorage) GetObject

func (s GCSStorage) GetObject(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, objectKey string) (io.ReadCloser, error)

func (GCSStorage) IsObjectsInBucket

func (s GCSStorage) IsObjectsInBucket(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupObject string) (bool, error)

func (GCSStorage) IsSnapshotExisted

func (s GCSStorage) IsSnapshotExisted(cloudCredentialsFile, bslConfig, backupObject string, snapshotCheck test.SnapshotCheckPoint) error

type ObjectsInStorage

type ObjectsInStorage interface {
	IsObjectsInBucket(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupObject string) (bool, error)
	DeleteObjectsInBucket(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, backupObject string) error
	IsSnapshotExisted(cloudCredentialsFile, bslConfig, backupName string, snapshotCheck velerotest.SnapshotCheckPoint) error
	GetObject(cloudCredentialsFile, bslBucket, bslPrefix, bslConfig, objectKey string) (io.ReadCloser, error)
}

Jump to

Keyboard shortcuts

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