Documentation ¶
Index ¶
- func CVCKey(cvc *apisv1.CStorVolumeConfig) string
- type Builder
- func (b *Builder) Build() (*apisv1.CStorVolumeConfig, error)
- func (b *Builder) WithAnnotations(annotations map[string]string) *Builder
- func (b *Builder) WithAnnotationsNew(annotations map[string]string) *Builder
- func (b *Builder) WithCapacity(capacity string) *Builder
- func (b *Builder) WithCapacityQty(resCapacity resource.Quantity) *Builder
- func (b *Builder) WithDependentsUpgraded() *Builder
- func (b *Builder) WithFinalizers(finalizers []string) *Builder
- func (b *Builder) WithFinalizersNew(finalizers []string) *Builder
- func (b *Builder) WithGenerateName(name string) *Builder
- func (b *Builder) WithLabels(labels map[string]string) *Builder
- func (b *Builder) WithLabelsNew(labels map[string]string) *Builder
- func (b *Builder) WithName(name string) *Builder
- func (b *Builder) WithNamespace(namespace string) *Builder
- func (b *Builder) WithNewVersion(version string) *Builder
- func (b *Builder) WithNodeID(nodeID string) *Builder
- func (b *Builder) WithProvisionCapacityQty(resCapacity resource.Quantity) *Builder
- func (b *Builder) WithReplicaCount(count string) *Builder
- func (b *Builder) WithSource(volumeSource string) *Builder
- func (b *Builder) WithStatusConditions(conditions []apisv1.CStorVolumeConfigCondition) *Builder
- func (b *Builder) WithStatusConditionsNew(conditions []apisv1.CStorVolumeConfigCondition) *Builder
- func (b *Builder) WithStatusPhase(phase apisv1.CStorVolumeConfigPhase) *Builder
- type CStorVolumeConfig
- type CStorVolumeConfigList
- type Kubeclient
- func (k *Kubeclient) Create(cvc *apismaya.CStorVolumeConfig) (*apismaya.CStorVolumeConfig, error)
- func (k *Kubeclient) Delete(name string) error
- func (k *Kubeclient) Get(name string, opts metav1.GetOptions) (*apismaya.CStorVolumeConfig, error)
- func (k *Kubeclient) GetRaw(name string, opts metav1.GetOptions) ([]byte, error)
- func (k *Kubeclient) List(opts metav1.ListOptions) (*apismaya.CStorVolumeConfigList, error)
- func (k *Kubeclient) Patch(oldCVC *apismaya.CStorVolumeConfig, newCVC *apismaya.CStorVolumeConfig, ...) (*apismaya.CStorVolumeConfig, error)
- func (k *Kubeclient) Update(cvc *apismaya.CStorVolumeConfig) (*apismaya.CStorVolumeConfig, error)
- func (k *Kubeclient) WithNamespace(namespace string) *Kubeclient
- type KubeclientBuildOption
- type ListBuilder
- type Predicate
- type PredicateList
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CVCKey ¶
func CVCKey(cvc *apisv1.CStorVolumeConfig) string
CVCKey returns an unique key of a CVC object,
Types ¶
type Builder ¶
type Builder struct {
// contains filtered or unexported fields
}
Builder is the builder object for CStorVolumeConfig
func BuildFrom ¶
func BuildFrom(cvc *apisv1.CStorVolumeConfig) *Builder
BuildFrom returns new instance of Builder from the provided api instance
func (*Builder) Build ¶
func (b *Builder) Build() (*apisv1.CStorVolumeConfig, error)
Build returns the CStorVolumeConfig API instance
func (*Builder) WithAnnotations ¶
WithAnnotations merges existing annotations of CStorVolumeConfig if any with the ones that are provided here
func (*Builder) WithAnnotationsNew ¶
WithAnnotationsNew resets existing annotations of CStorVolumeiClaim if any with ones that are provided here
func (*Builder) WithCapacity ¶
WithCapacity sets the Capacity of CstorVOlumeClaim by converting string capacity into Quantity
func (*Builder) WithCapacityQty ¶
WithCapacityQty sets Capacity of CStorVOlumeClaim
func (*Builder) WithDependentsUpgraded ¶
WithDependentsUpgraded sets the field to true for new volume
func (*Builder) WithFinalizers ¶
WithFinalizers merges existing finalizers of CStorVolumeConfig if any with the ones that are provided here
func (*Builder) WithFinalizersNew ¶
WithFinalizersNew resets existing finalizers of CStorVolumeConfig if any with ones that are provided here
func (*Builder) WithGenerateName ¶
WithGenerateName sets the GenerateName of CStorVolumeConfig
func (*Builder) WithLabels ¶
WithLabels merges existing labels of CStorVolumeConfig if any with the ones that are provided here
func (*Builder) WithLabelsNew ¶
WithLabelsNew resets existing labels of CStorVolumeConfig if any with ones that are provided here
func (*Builder) WithNamespace ¶
WithNamespace resets the Namespace of CStorVolumeConfig with provided arguments
func (*Builder) WithNewVersion ¶
WithNewVersion sets the current and desired version field of CStorVolume with provided arguments
func (*Builder) WithNodeID ¶
WithNodeID sets NodeID details of CStorVolumeConfig
func (*Builder) WithProvisionCapacityQty ¶
WithProvisionCapacityQty sets initial provided Capacity of CStorVOlumeClaim as a readonly capacity requires in case of volume day2 operations
func (*Builder) WithReplicaCount ¶
WithReplicaCount sets replica count of CStorVolumeConfig
func (*Builder) WithSource ¶
WithSource sets the source of CstorVOlume
func (*Builder) WithStatusConditions ¶
func (b *Builder) WithStatusConditions( conditions []apisv1.CStorVolumeConfigCondition) *Builder
WithStatusConditions updates the status of CStorVolumeConfig
func (*Builder) WithStatusConditionsNew ¶
func (b *Builder) WithStatusConditionsNew( conditions []apisv1.CStorVolumeConfigCondition) *Builder
WithStatusConditionsNew resets the status of CStorVolumeConfig
func (*Builder) WithStatusPhase ¶
func (b *Builder) WithStatusPhase( phase apisv1.CStorVolumeConfigPhase) *Builder
WithStatusPhase updates the phase of CStorVolumeConfig
type CStorVolumeConfig ¶
type CStorVolumeConfig struct {
// contains filtered or unexported fields
}
CStorVolumeConfig a wrapper for ume object
func NewForAPIObject ¶
func NewForAPIObject(obj *apisv1.CStorVolumeConfig) *CStorVolumeConfig
NewForAPIObject returns a new instance of cstorvolume
type CStorVolumeConfigList ¶
type CStorVolumeConfigList struct {
// contains filtered or unexported fields
}
List is a list of cstorvolumeclaim objects
func (*CStorVolumeConfigList) Len ¶
func (l *CStorVolumeConfigList) Len() int
Len returns the number of items present in the CStorVolumeConfigList
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 ¶
func (k *Kubeclient) Create( cvc *apismaya.CStorVolumeConfig) (*apismaya.CStorVolumeConfig, error)
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, ) (*apismaya.CStorVolumeConfig, 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 ¶
func (k *Kubeclient) List( opts metav1.ListOptions, ) (*apismaya.CStorVolumeConfigList, error)
List returns a list of cstorvolumeclaim instances present in kubernetes cluster
func (*Kubeclient) Patch ¶
func (k *Kubeclient) Patch( oldCVC *apismaya.CStorVolumeConfig, newCVC *apismaya.CStorVolumeConfig, subresources ...string, ) (*apismaya.CStorVolumeConfig, error)
Patch patches this cstorvolumeclaim instance against kubernetes cluster
func (*Kubeclient) Update ¶
func (k *Kubeclient) Update( cvc *apismaya.CStorVolumeConfig, ) (*apismaya.CStorVolumeConfig, 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 umeCStorVolumeConfigList
func NewListBuilder ¶
func NewListBuilder() *ListBuilder
NewListBuilder returns a new instance of listBuilder
func (*ListBuilder) List ¶
func (b *ListBuilder) List() *CStorVolumeConfigList
List returns the list of CStorVolumeConfigs (cvcs) instances that was built by this builder
func (*ListBuilder) WithAPIList ¶
func (b *ListBuilder) WithAPIList( list *apisv1.CStorVolumeConfigList) *ListBuilder
WithAPIList builds the list of cstorvolume claim instances based on the provided CStorVolumeConfig 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(*CStorVolumeConfig) 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