Help us shape the future of Go! Take the 2026 Go Developer Survey

client

package
v0.4.13 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OCSProviderClient

type OCSProviderClient struct {
	Client pb.OCSProviderClient
	// contains filtered or unexported fields
}

func NewProviderClient

func NewProviderClient(ctx context.Context, serverAddr string, timeout time.Duration) (*OCSProviderClient, error)

NewProviderClient creates a client to talk to the external OCS storage provider server

func (*OCSProviderClient) AcknowledgeOnboarding

func (cc *OCSProviderClient) AcknowledgeOnboarding(ctx context.Context, consumerUUID string) (*pb.AcknowledgeOnboardingResponse, error)

func (*OCSProviderClient) Close

func (cc *OCSProviderClient) Close()

Close closes the gRPC connection of the external OCS storage provider client

func (*OCSProviderClient) FulfillStorageClassClaim added in v0.4.11

func (cc *OCSProviderClient) FulfillStorageClassClaim(
	ctx context.Context,
	consumerUUID string,
	storageClassClaimName string,
	storageType StorageType,
	storageProfile string,
	encryptionMethod string,
) (*pb.FulfillStorageClassClaimResponse, error)

func (*OCSProviderClient) GetStorageClassClaimConfig added in v0.4.11

func (cc *OCSProviderClient) GetStorageClassClaimConfig(ctx context.Context, consumerUUID, storageClassClaimName string) (*pb.StorageClassClaimConfigResponse, error)

func (*OCSProviderClient) GetStorageConfig

func (cc *OCSProviderClient) GetStorageConfig(ctx context.Context, consumerUUID string) (*pb.StorageConfigResponse, error)

GetStorageConfig generates the json config for connecting to storage provider cluster

func (*OCSProviderClient) OffboardConsumer

func (cc *OCSProviderClient) OffboardConsumer(ctx context.Context, consumerUUID string) (*pb.OffboardConsumerResponse, error)

OffboardConsumer deletes the StorageConsumer CR on the storage provider cluster

func (*OCSProviderClient) OnboardConsumer

func (cc *OCSProviderClient) OnboardConsumer(ctx context.Context, ticket, name, capacity string) (*pb.OnboardConsumerResponse, error)

OnboardConsumer to validate the consumer and create StorageConsumer resource on the StorageProvider cluster

func (*OCSProviderClient) ReportStatus added in v0.4.11

func (cc *OCSProviderClient) ReportStatus(ctx context.Context, consumerUUID string) (*pb.ReportStatusResponse, error)

func (*OCSProviderClient) RevokeStorageClassClaim added in v0.4.11

func (cc *OCSProviderClient) RevokeStorageClassClaim(ctx context.Context, consumerUUID, storageClassClaimName string) (*pb.RevokeStorageClassClaimResponse, error)

func (*OCSProviderClient) UpdateCapacity

func (cc *OCSProviderClient) UpdateCapacity(ctx context.Context, consumerUUID, capacity string) (*pb.UpdateCapacityResponse, error)

UpdateCapacity increases or decreases the storage block pool size

type StorageType added in v0.4.11

type StorageType uint
const (
	StorageTypeBlockpool StorageType = iota
	StorageTypeSharedfilesystem
)

Jump to

Keyboard shortcuts

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