wait

package
v0.15.0 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2024 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

View Source
const (
	InstanceStateEmpty      = ""
	InstanceStateProcessing = "PROCESSING"
	InstanceStateUnknown    = "UNKNOWN"
	InstanceStateSuccess    = "READY"
	InstanceStateFailed     = "FAILED"

	RestoreJobProcessing = "IN_PROGRESS"
	RestoreJobFinished   = "FINISHED"
	RestoreJobBroken     = "BROKEN"
	RestoreJobKilled     = "KILLED"
)

Variables

This section is empty.

Functions

func CloneInstanceWaitHandler

func CloneInstanceWaitHandler(ctx context.Context, a APIClientInstanceInterface, projectId, instanceId string) *wait.AsyncActionHandler[mongodbflex.GetInstanceResponse]

CloneInstanceWaitHandler will wait for instance clone to be created

func CreateInstanceWaitHandler

func CreateInstanceWaitHandler(ctx context.Context, a APIClientInstanceInterface, projectId, instanceId string) *wait.AsyncActionHandler[mongodbflex.GetInstanceResponse]

CreateInstanceWaitHandler will wait for instance creation

func DeleteInstanceWaitHandler

func DeleteInstanceWaitHandler(ctx context.Context, a APIClientInstanceInterface, projectId, instanceId string) *wait.AsyncActionHandler[struct{}]

DeleteInstanceWaitHandler will wait for instance deletion

func PartialUpdateInstanceWaitHandler

func PartialUpdateInstanceWaitHandler(ctx context.Context, a APIClientInstanceInterface, projectId, instanceId string) *wait.AsyncActionHandler[mongodbflex.GetInstanceResponse]

PartialUpdateInstanceWaitHandler will wait for instance update

func RestoreInstanceWaitHandler added in v0.13.0

func RestoreInstanceWaitHandler(ctx context.Context, a APIClientInstanceInterface, projectId, instanceId, backupId string) *wait.AsyncActionHandler[mongodbflex.ListRestoreJobsResponse]

func UpdateInstanceWaitHandler

func UpdateInstanceWaitHandler(ctx context.Context, a APIClientInstanceInterface, projectId, instanceId string) *wait.AsyncActionHandler[mongodbflex.GetInstanceResponse]

UpdateInstanceWaitHandler will wait for instance update

Types

type APIClientInstanceInterface

type APIClientInstanceInterface interface {
	GetInstanceExecute(ctx context.Context, projectId, instanceId string) (*mongodbflex.GetInstanceResponse, error)
	ListRestoreJobsExecute(ctx context.Context, projectId, instanceId string) (*mongodbflex.ListRestoreJobsResponse, error)
}

Interface needed for tests

Jump to

Keyboard shortcuts

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