aws

package
v1.1.0-beta.0...-3c40731 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	FsrApiSnapshotsThreshold = 10
)

Variables

This section is empty.

Functions

This section is empty.

Types

type EC2Session

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

func NewEC2Session

func NewEC2Session(concurrency uint, region string) (*EC2Session, error)

func (*EC2Session) CreateSnapshots

func (e *EC2Session) CreateSnapshots(backupInfo *config.EBSBasedBRMeta) (map[string]string, VolumeAZs, error)

CreateSnapshots is the mainly steps to control the data volume snapshots.

func (*EC2Session) CreateVolumes

func (e *EC2Session) CreateVolumes(meta *config.EBSBasedBRMeta, volumeType string, iops, throughput int64, encrypted bool, targetAZ string) (map[string]string, error)

CreateVolumes create volumes from snapshots if err happens in the middle, return half-done result returned map: store id -> old volume id -> new volume id

func (*EC2Session) DeleteSnapshots

func (e *EC2Session) DeleteSnapshots(snapIDMap map[string]string)

func (*EC2Session) DeleteVolumes

func (e *EC2Session) DeleteVolumes(volumeIDMap map[string]string)

func (*EC2Session) DisableDataFSR

func (e *EC2Session) DisableDataFSR(snapshotsIDsMap map[string][]*string) error

DisableDataFSR disables FSR for data volume snapshots

func (*EC2Session) EnableDataFSR

func (e *EC2Session) EnableDataFSR(meta *config.EBSBasedBRMeta, targetAZ string) (map[string][]*string, error)

EnableDataFSR enables FSR for data volume snapshots

func (*EC2Session) HandleDescribeVolumesResponse

func (e *EC2Session) HandleDescribeVolumesResponse(resp *ec2.DescribeVolumesOutput, fsrEnabledRequired bool) (int64, []*string, error)

func (*EC2Session) WaitSnapshotsCreated

func (e *EC2Session) WaitSnapshotsCreated(snapIDMap map[string]string, progress glue.Progress) (int64, error)

WaitSnapshotsCreated waits all snapshots finished. according to EBS snapshot will do real snapshot background. so we'll check whether all snapshots finished.

func (*EC2Session) WaitVolumesCreated

func (e *EC2Session) WaitVolumesCreated(volumeIDMap map[string]string, progress glue.Progress, fsrEnabledRequired bool) (int64, error)

type VolumeAZs

type VolumeAZs map[string]string

Jump to

Keyboard shortcuts

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