aws

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2023 License: Apache-2.0, Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

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, 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) HandleDescribeVolumesResponse

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

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) (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