v1alpha1

package
v1.10.0 Latest Latest
Warning

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

Go to latest
Published: May 14, 2020 License: Apache-2.0 Imports: 12 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CVCKey

func CVCKey(cvc *apis.CStorVolumeClaim) string

CVCKey returns an unique key of a CVC object,

func GetDesiredReplicaPoolNames

func GetDesiredReplicaPoolNames(cvc *apis.CStorVolumeClaim) []string

GetDesiredReplicaPoolNames returns list of desired pool names

func GetPDBLabels

func GetPDBLabels(poolNames []string, cspcName string) map[string]string

GetPDBLabels returns the labels required for building PDB based on arguments

func GetPDBPoolLabels

func GetPDBPoolLabels(poolNames []string) map[string]string

GetPDBPoolLabels returns the pool labels from poolNames

Types

type Builder

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

Builder is the builder object for CStorVolumeClaim

func BuildFrom

func BuildFrom(cvc *apis.CStorVolumeClaim) *Builder

BuildFrom returns new instance of Builder from the provided api instance

func NewBuilder

func NewBuilder() *Builder

NewBuilder returns new instance of Builder

func (*Builder) Build

func (b *Builder) Build() (*apis.CStorVolumeClaim, error)

Build returns the CStorVolumeClaim API instance

func (*Builder) WithAnnotations

func (b *Builder) WithAnnotations(annotations map[string]string) *Builder

WithAnnotations merges existing annotations of CStorVolumeClaim if any with the ones that are provided here

func (*Builder) WithAnnotationsNew

func (b *Builder) WithAnnotationsNew(annotations map[string]string) *Builder

WithAnnotationsNew resets existing annotations of CStorVolumeiClaim if any with ones that are provided here

func (*Builder) WithCapacity

func (b *Builder) WithCapacity(capacity string) *Builder

WithCapacity sets the Capacity of CstorVOlumeClaim by converting string capacity into Quantity

func (*Builder) WithCapacityQty

func (b *Builder) WithCapacityQty(resCapacity resource.Quantity) *Builder

WithCapacityQty sets Capacity of CStorVolumeClaim

func (*Builder) WithFinalizers

func (b *Builder) WithFinalizers(finalizers []string) *Builder

WithFinalizers merges existing finalizers of CStorVolumeClaim if any with the ones that are provided here

func (*Builder) WithFinalizersNew

func (b *Builder) WithFinalizersNew(finalizers []string) *Builder

WithFinalizersNew resets existing finalizers of CStorVolumeClaim if any with ones that are provided here

func (*Builder) WithGenerateName

func (b *Builder) WithGenerateName(name string) *Builder

WithGenerateName sets the GenerateName of CStorVolumeClaim

func (*Builder) WithLabels

func (b *Builder) WithLabels(labels map[string]string) *Builder

WithLabels merges existing labels of CStorVolumeClaim if any with the ones that are provided here

func (*Builder) WithLabelsNew

func (b *Builder) WithLabelsNew(labels map[string]string) *Builder

WithLabelsNew resets existing labels of CStorVolumeClaim if any with ones that are provided here

func (*Builder) WithName

func (b *Builder) WithName(name string) *Builder

WithName sets the Name of CStorVolumeClaim

func (*Builder) WithNamespace

func (b *Builder) WithNamespace(namespace string) *Builder

WithNamespace resets the Namespace of CStorVolumeClaim with provided arguments

func (*Builder) WithNodeID

func (b *Builder) WithNodeID(nodeID string) *Builder

WithNodeID sets NodeID details of CStorVolumeClaim

func (*Builder) WithReplicaCount

func (b *Builder) WithReplicaCount(count string) *Builder

WithReplicaCount sets replica count of CStorVolumeClaim

func (*Builder) WithStatusConditions

func (b *Builder) WithStatusConditions(
	conditions []apis.CStorVolumeClaimCondition) *Builder

WithStatusConditions updates the status of CStorVolumeClaim

func (*Builder) WithStatusConditionsNew

func (b *Builder) WithStatusConditionsNew(
	conditions []apis.CStorVolumeClaimCondition) *Builder

WithStatusConditionsNew resets the status of CStorVolumeClaim

func (*Builder) WithStatusPhase

func (b *Builder) WithStatusPhase(
	phase apis.CStorVolumeClaimPhase) *Builder

WithStatusPhase updates the phase of CStorVolumeClaim

type CStorVolumeClaim

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

CStorVolumeClaim a wrapper for ume object

func NewForAPIObject

func NewForAPIObject(obj *apis.CStorVolumeClaim) *CStorVolumeClaim

NewForAPIObject returns a new instance of cstorvolume

type CStorVolumeClaimList

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

CStorVolumeClaimList is a list of cstorvolumeclaim objects

func (*CStorVolumeClaimList) Len

func (l *CStorVolumeClaimList) Len() int

Len returns the number of items present in the CStorVolumeClaimList

type Kubeclient

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

Kubeclient enables kubernetes API operations on csi volume instance

func NewKubeclient

func NewKubeclient(opts ...KubeclientBuildOption) *Kubeclient

NewKubeclient returns a new instance of kubeclient meant for csi volume operations

func (*Kubeclient) Create

Create creates a cstorvolumeclaim instance in kubernetes cluster

func (*Kubeclient) Delete

func (k *Kubeclient) Delete(name string) error

Delete deletes the cstorvolumeclaim from kubernetes

func (*Kubeclient) Get

func (k *Kubeclient) Get(
	name string,
	opts metav1.GetOptions,
) (*apis.CStorVolumeClaim, error)

Get returns cstorvolumeclaim object for given name

func (*Kubeclient) GetRaw

func (k *Kubeclient) GetRaw(
	name string,
	opts metav1.GetOptions,
) ([]byte, error)

GetRaw returns cstorvolumeclaim instance in bytes

func (*Kubeclient) List

List returns a list of cstorvolumeclaim instances present in kubernetes cluster

func (*Kubeclient) Patch

func (k *Kubeclient) Patch(
	oldCVC, newCVC *apis.CStorVolumeClaim,
	subresources ...string,
) (*apis.CStorVolumeClaim, error)

Patch patches this cstorvolumeclaim instance against kubernetes cluster

func (*Kubeclient) Update

func (k *Kubeclient) Update(
	cvc *apis.CStorVolumeClaim,
) (*apis.CStorVolumeClaim, error)

Update updates this cstorvolumeclaim instance against kubernetes cluster

func (*Kubeclient) WithNamespace

func (k *Kubeclient) WithNamespace(namespace string) *Kubeclient

WithNamespace sets the provided namespace against this Kubeclient instance

type KubeclientBuildOption

type KubeclientBuildOption func(*Kubeclient)

KubeclientBuildOption defines the abstraction to build a kubeclient instance

func WithClientSet

func WithClientSet(c *clientset.Clientset) KubeclientBuildOption

WithClientSet sets the kubernetes client against the kubeclient instance

func WithKubeConfigPath

func WithKubeConfigPath(path string) KubeclientBuildOption

WithKubeConfigPath sets the kubernetes client against the provided path

func WithNamespace

func WithNamespace(namespace string) KubeclientBuildOption

WithNamespace sets the kubernetes client against the provided namespace

type ListBuilder

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

ListBuilder enables building an instance of umeCStorVolumeClaimList

func NewListBuilder

func NewListBuilder() *ListBuilder

NewListBuilder returns a new instance of listBuilder

func (*ListBuilder) List

func (b *ListBuilder) List() *CStorVolumeClaimList

List returns the list of CStorVolumeClaims (cvcs) instances that was built by this builder

func (*ListBuilder) WithAPIList

func (b *ListBuilder) WithAPIList(
	list *apis.CStorVolumeClaimList) *ListBuilder

WithAPIList builds the list of cstorvolume claim instances based on the provided CStorVolumeClaim api instances

func (*ListBuilder) WithFilter

func (b *ListBuilder) WithFilter(pred ...Predicate) *ListBuilder

WithFilter adds filters on which the cstorvolumeclaim has to be filtered

type Predicate

type Predicate func(*CStorVolumeClaim) bool

Predicate defines an abstraction to determine conditional checks against the provided cstorvolume claim instance

type PredicateList

type PredicateList []Predicate

PredicateList holds a list of cstor volume claims based predicates

Jump to

Keyboard shortcuts

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