postgresflexalpha

package
v0.0.23-alpha Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2026 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	InstanceStateEmpty       = ""
	InstanceStateProgressing = "PROGRESSING"
	InstanceStateSuccess     = "READY"
	InstanceStateFailed      = "FAILURE"
	InstanceStateTerminating = "TERMINATING"
	InstanceStateUnknown     = "UNKNOWN"
	InstanceStatePending     = "PENDING"
)

"READY" "PENDING" "PROGRESSING" "FAILURE" "UNKNOWN" "TERMINATING"

Variables

This section is empty.

Functions

func CreateInstanceWaitHandler

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

CreateInstanceWaitHandler will wait for instance creation

func GetDatabaseByIdWaitHandler

func GetDatabaseByIdWaitHandler(
	ctx context.Context,
	a APIClientUserInterface,
	projectId, instanceId, region string,
	databaseId int64,
) *wait.AsyncActionHandler[postgresflex.GetDatabaseResponse]

GetDatabaseByIdWaitHandler will wait for instance creation

func GetUserByIdWaitHandler

func GetUserByIdWaitHandler(
	ctx context.Context,
	a APIClientUserInterface,
	projectId, instanceId, region string,
	userId int64,
) *wait.AsyncActionHandler[postgresflex.GetUserResponse]

GetUserByIdWaitHandler will wait for instance creation

func PartialUpdateInstanceWaitHandler

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

PartialUpdateInstanceWaitHandler will wait for instance update

Types

type APIClientInstanceInterface

type APIClientInstanceInterface interface {
	GetInstanceRequestExecute(ctx context.Context, projectId, region, instanceId string) (
		*postgresflex.GetInstanceResponse,
		error,
	)

	ListUsersRequestExecute(
		ctx context.Context,
		projectId string,
		region string,
		instanceId string,
	) (*postgresflex.ListUserResponse, error)
}

APIClientInstanceInterface Interface needed for tests

type APIClientUserInterface

type APIClientUserInterface interface {
	GetUserRequestExecute(ctx context.Context, projectId, region, instanceId string, userId int32) (
		*postgresflex.GetUserResponse,
		error,
	)

	GetDatabaseRequestExecute(
		ctx context.Context,
		projectId string,
		region string,
		instanceId string,
		databaseId int32,
	) (*postgresflex.GetDatabaseResponse, error)
}

APIClientUserInterface Interface needed for tests

Jump to

Keyboard shortcuts

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