Documentation ¶
Overview ¶
Package v1alpha1 contains API Schema definitions for the localstorage v1alpha1 API group +k8s:deepcopy-gen=package,register +groupName=hwameistor.io
Package v1alpha1 contains v1alpha1 API versions.
This file ensures Go source parsers acknowledge the v1alpha1 package and any child packages. It can be removed if any other Go source files are added to this package.
Package v1alpha1 contains API Schema definitions for the localstorage v1alpha1 API group +k8s:deepcopy-gen=package,register +groupName=hwameistor.io
Index ¶
- Constants
- Variables
- func AddToScheme(s *runtime.Scheme) error
- func Kind(kind string) schema.GroupKind
- func Resource(resource string) schema.GroupResource
- type AccessibilityTopology
- type DRBDSystemConfig
- type HAState
- type LocalDisk
- type LocalPool
- type LocalStorageNode
- type LocalStorageNodeList
- type LocalStorageNodeSpec
- type LocalStorageNodeStatus
- type LocalVolume
- type LocalVolumeConvert
- type LocalVolumeConvertList
- type LocalVolumeConvertSpec
- type LocalVolumeConvertStatus
- type LocalVolumeExpand
- type LocalVolumeExpandList
- type LocalVolumeExpandSpec
- type LocalVolumeExpandStatus
- type LocalVolumeGroup
- type LocalVolumeGroupConvert
- type LocalVolumeGroupConvertList
- type LocalVolumeGroupConvertSpec
- type LocalVolumeGroupConvertStatus
- type LocalVolumeGroupList
- type LocalVolumeGroupMigrate
- type LocalVolumeGroupMigrateList
- type LocalVolumeGroupMigrateSpec
- type LocalVolumeGroupMigrateStatus
- type LocalVolumeGroupSpec
- type LocalVolumeGroupStatus
- type LocalVolumeList
- type LocalVolumeMigrate
- type LocalVolumeMigrateList
- type LocalVolumeMigrateSpec
- type LocalVolumeMigrateStatus
- type LocalVolumeReplica
- type LocalVolumeReplicaList
- type LocalVolumeReplicaSpec
- type LocalVolumeReplicaStatus
- type LocalVolumeSpec
- type LocalVolumeStatus
- type NodeConfig
- type Phase
- type State
- type SystemConfig
- type SystemMode
- type Topology
- type VolumeConfig
- type VolumeGroupManager
- type VolumeInfo
- type VolumeReplica
- type VolumeScheduler
Constants ¶
const ( NodeStateReady State = "Ready" NodeStateMaintain State = "Maintain" NodeStateOffline State = "Offline" VolumeStateCreating State = "Creating" VolumeStateReady State = "Ready" VolumeStateNotReady State = "NotReady" VolumeStateToBeDeleted State = "ToBeDeleted" VolumeStateDeleted State = "Deleted" VolumeReplicaStateInvalid State = "Invalid" VolumeReplicaStateCreating State = "Creating" VolumeReplicaStateReady State = "Ready" VolumeReplicaStateNotReady State = "NotReady" VolumeReplicaStateToBeDeleted State = "ToBeDeleted" VolumeReplicaStateDeleted State = "Deleted" // ha replica state HAVolumeReplicaStateConsistent State = "Consistent" HAVolumeReplicaStateInconsistent State = "Inconsistent" HAVolumeReplicaStateUp State = "Up" HAVolumeReplicaStateDown State = "Down" // purpose of the following CRDs is for operational job, // so, they will be in different state machine from volume/volumereplica OperationStateSubmitted State = "Submitted" OperationStateInProgress State = "InProgress" OperationStateCompleted State = "Completed" OperationStateToBeAborted State = "ToBeAborted" OperationStateAborting State = "Cancelled" OperationStateAborted State = "Aborted" OperationStateFailed State = "Failed" DiskStateAvailable State = "Available" DiskStateInUse State = "InUse" DiskStateOffline State = "Offline" LVMVolumeMaxCount int64 = 1000 RAMVolumeMaxCount int64 = 1000 VolumeKindLVM = "LVM" VolumeExpansionCapacityBytesMin int64 = 10 * 1024 * 1024 // 10MiB StoragePoolCapacityThresholdRatio = 0.85 VolumeMigratePhaseMove Phase = "Move" VolumeMigratePhasePrune Phase = "Prune" )
states
const ( DiskClassNameHDD = "HDD" DiskClassNameSSD = "SSD" DiskClassNameNVMe = "NVMe" )
disk class
const ( PoolNamePrefix = "LocalStorage_Pool" PoolNameForHDD = PoolNamePrefix + DiskClassNameHDD PoolNameForSSD = PoolNamePrefix + DiskClassNameSSD PoolNameForNVMe = PoolNamePrefix + DiskClassNameNVMe PoolTypeRegular = "REGULAR" )
consts
const ( VolumeParameterPoolClassKey = "poolClass" VolumeParameterPoolTypeKey = "poolType" VolumeParameterReplicaNumberKey = "replicaNumber" VolumeParameterFSTypeKey = "csi.storage.k8s.io/fstype" VolumeParameterConvertible = "convertible" )
consts
const ( CSIDriverName = "lvm.hwameistor.io" VendorName = "hwameistor.io" )
misc
const ( DiskDevRootPath = "/dev" AssigedDiskPool = DiskDevRootPath + "/LocalStorage_DiskPool" AssigedDiskPoolHDD = AssigedDiskPool + DiskClassNameHDD AssigedDiskPoolSSD = AssigedDiskPool + DiskClassNameSSD AssigedDiskPoolNVMe = AssigedDiskPool + DiskClassNameNVMe )
localstorage local storage dev paths
const (
StorageIPv4AddressAnnotationKeyEnv = "NODE_ANNOTATION_KEY_STORAGE_IPV4"
)
k8snode
Variables ¶
var ( // SchemeGroupVersion is group version used to register these objects SchemeGroupVersion = schema.GroupVersion{Group: "hwameistor.io", Version: "v1alpha1"} // SchemeBuilder is used to add go types to the GroupVersionKind scheme for Local Storage Member SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion} )
var AddToSchemes runtime.SchemeBuilder
AddToSchemes may be used to add all resources defined in the project to a Scheme for Local Storage Member
Functions ¶
func AddToScheme ¶
AddToScheme adds all Resources to the Scheme for Local Storage Member
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type AccessibilityTopology ¶
type AccessibilityTopology struct { // Nodes is the collection of storage nodes the volume replicas must locate at Nodes []string `json:"nodes,omitempty"` // zones where the volume replicas should be distributed across, it's Optional // +kubebuilder:default:={default} Zones []string `json:"zones,omitempty"` // regions where the volume replicas should be distributed across, it's Optional // +kubebuilder:default:={default} Regions []string `json:"regions,omitempty"` }
AccessibilityTopology of the volume
func (*AccessibilityTopology) DeepCopy ¶
func (in *AccessibilityTopology) DeepCopy() *AccessibilityTopology
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AccessibilityTopology.
func (*AccessibilityTopology) DeepCopyInto ¶
func (in *AccessibilityTopology) DeepCopyInto(out *AccessibilityTopology)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type DRBDSystemConfig ¶
DRBDSystemConfig of HA module
func (*DRBDSystemConfig) DeepCopy ¶
func (in *DRBDSystemConfig) DeepCopy() *DRBDSystemConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DRBDSystemConfig.
func (*DRBDSystemConfig) DeepCopyInto ¶
func (in *DRBDSystemConfig) DeepCopyInto(out *DRBDSystemConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type HAState ¶
type HAState struct { // Consistent, Inconsistent, replica is ready only when consistent State State `json:"state"` // Reason is why this state happened Reason string `json:"reason,omitempty"` }
HAState is state for ha replica
func (*HAState) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new HAState.
func (*HAState) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalDisk ¶
type LocalDisk struct { // e.g. /dev/sdb DevPath string `json:"devPath,omitempty"` // Supported: HDD, SSD, NVMe, RAM Class string `json:"type,omitempty"` // disk capacity CapacityBytes int64 `json:"capacityBytes,omitempty"` // Possible state: Available, Inuse, Offline State State `json:"state,omitempty"` }
LocalDisk is disk struct
func (*LocalDisk) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalDisk.
func (*LocalDisk) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalPool ¶
type LocalPool struct { // Supported pool name: HDD_POOL, SSD_POOL, NVMe_POOL Name string `json:"name,omitempty"` // Supported class: HDD, SSD, NVMe // +kubebuilder:validation:Enum:=HDD;SSD;NVMe Class string `json:"class"` // Supported type: REGULAR // +kubebuilder:validation:Enum:=REGULAR // +kubebuilder:default:=REGULAR Type string `json:"type"` // VG path Path string `json:"path,omitempty"` TotalCapacityBytes int64 `json:"totalCapacityBytes"` UsedCapacityBytes int64 `json:"usedCapacityBytes"` VolumeCapacityBytesLimit int64 `json:"volumeCapacityBytesLimit"` FreeCapacityBytes int64 `json:"freeCapacityBytes"` TotalVolumeCount int64 `json:"totalVolumeCount"` UsedVolumeCount int64 `json:"usedVolumeCount"` FreeVolumeCount int64 `json:"freeVolumeCount"` Disks []LocalDisk `json:"disks,omitempty"` Volumes []string `json:"volumes,omitempty"` }
LocalPool is storage pool struct
func (*LocalPool) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalPool.
func (*LocalPool) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalStorageNode ¶
type LocalStorageNode struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalStorageNodeSpec `json:"spec,omitempty"` Status LocalStorageNodeStatus `json:"status,omitempty"` }
LocalStorageNode is the Schema for the localstoragenodes API +kubebuilder:subresource:status +kubebuilder:resource:path=localstoragenodes,scope=Cluster,shortName=lsn +kubebuilder:printcolumn:name="ip",type=string,JSONPath=`.spec.storageIP`,description="IPv4 address" +kubebuilder:printcolumn:name="volumekind",type=string,JSONPath=`.spec.allowedVolumeKind`,description="volume kind" +kubebuilder:printcolumn:name="ramdiskQuota",type=integer,JSONPath=`.spec.allowedRAMDiskTotalCapacityBytes`,description="total storage space of ramdisk" +kubebuilder:printcolumn:name="zone",type=string,JSONPath=`.spec.topogoly.zone`,description="Zone of the node" +kubebuilder:printcolumn:name="region",type=string,JSONPath=`.spec.topogoly.region`,description="Region of the node" +kubebuilder:printcolumn:name="status",type=string,JSONPath=`.status.state`,description="State of the Local Storage Node" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalStorageNode) DeepCopy ¶
func (in *LocalStorageNode) DeepCopy() *LocalStorageNode
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalStorageNode.
func (*LocalStorageNode) DeepCopyInto ¶
func (in *LocalStorageNode) DeepCopyInto(out *LocalStorageNode)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalStorageNode) DeepCopyObject ¶
func (in *LocalStorageNode) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalStorageNodeList ¶
type LocalStorageNodeList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalStorageNode `json:"items"` }
LocalStorageNodeList contains a list of LocalStorageNode
func (*LocalStorageNodeList) DeepCopy ¶
func (in *LocalStorageNodeList) DeepCopy() *LocalStorageNodeList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalStorageNodeList.
func (*LocalStorageNodeList) DeepCopyInto ¶
func (in *LocalStorageNodeList) DeepCopyInto(out *LocalStorageNodeList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalStorageNodeList) DeepCopyObject ¶
func (in *LocalStorageNodeList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalStorageNodeSpec ¶
type LocalStorageNodeSpec struct { HostName string `json:"hostname,omitempty"` // IPv4 address is for HA replication traffic StorageIP string `json:"storageIP,omitempty"` Topo Topology `json:"topogoly,omitempty"` }
LocalStorageNodeSpec defines the desired state of LocalStorageNode
func (*LocalStorageNodeSpec) DeepCopy ¶
func (in *LocalStorageNodeSpec) DeepCopy() *LocalStorageNodeSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalStorageNodeSpec.
func (*LocalStorageNodeSpec) DeepCopyInto ¶
func (in *LocalStorageNodeSpec) DeepCopyInto(out *LocalStorageNodeSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalStorageNodeStatus ¶
type LocalStorageNodeStatus struct { // There may have multiple storage pools in a node. // e.g. HDD_POOL, SSD_POOL, NVMe_POOL // Pools: poolName -> LocalPool Pools map[string]LocalPool `json:"pools,omitempty"` // State of the Local Storage Node/Member: New, Active, Inactive, Failed State State `json:"state,omitempty"` }
LocalStorageNodeStatus defines the observed state of LocalStorageNode
func (*LocalStorageNodeStatus) DeepCopy ¶
func (in *LocalStorageNodeStatus) DeepCopy() *LocalStorageNodeStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalStorageNodeStatus.
func (*LocalStorageNodeStatus) DeepCopyInto ¶
func (in *LocalStorageNodeStatus) DeepCopyInto(out *LocalStorageNodeStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolume ¶
type LocalVolume struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalVolumeSpec `json:"spec,omitempty"` Status LocalVolumeStatus `json:"status,omitempty"` }
LocalVolume is the Schema for the volumes API +kubebuilder:subresource:status +kubebuilder:resource:path=localvolumes,scope=Cluster,shortName=lv +kubebuilder:printcolumn:name="pool",type=string,JSONPath=`.spec.poolName`,description="Name of storage pool" +kubebuilder:printcolumn:name="replicas",type=integer,JSONPath=`.spec.replicaNumber`,description="Number of volume replica" +kubebuilder:printcolumn:name="capacity",type=integer,JSONPath=`.spec.requiredCapacityBytes`,description="Required capacity of the volume" +kubebuilder:printcolumn:name="accessibility",type=string,JSONPath=`.spec.accessibility.node`,description="Accessibility of volume" +kubebuilder:printcolumn:name="state",type=string,JSONPath=`.status.state`,description="State of the volume" +kubebuilder:printcolumn:name="resource",type=integer,JSONPath=`.spec.config.resourceID`,description="Allocated resource ID for the volume" +kubebuilder:printcolumn:name="published",type=string,JSONPath=`.status.publishedNode`,description="Name of the node where the volume is in-use" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalVolume) DeepCopy ¶
func (in *LocalVolume) DeepCopy() *LocalVolume
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolume.
func (*LocalVolume) DeepCopyInto ¶
func (in *LocalVolume) DeepCopyInto(out *LocalVolume)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolume) DeepCopyObject ¶
func (in *LocalVolume) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*LocalVolume) IsHighAvailability ¶
func (v *LocalVolume) IsHighAvailability() bool
IsHighAvailability return true if volume is HighAvailability
func (*LocalVolume) SetReplicas ¶
func (v *LocalVolume) SetReplicas(replicas []*LocalVolumeReplica)
SetReplicas add replicas into status
type LocalVolumeConvert ¶
type LocalVolumeConvert struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalVolumeConvertSpec `json:"spec,omitempty"` Status LocalVolumeConvertStatus `json:"status,omitempty"` }
LocalVolumeConvert is the Schema for the localvolumeconverts API +kubebuilder:subresource:status +kubebuilder:resource:path=localvolumeconverts,scope=Cluster,shortName=lvconvert +kubebuilder:printcolumn:name="volume",type=string,JSONPath=`.spec.volumeName`,description="Name of the volume to convert" +kubebuilder:printcolumn:name="replicas",type=integer,JSONPath=`.spec.replicaNumber`,description="Number of volume replica" +kubebuilder:printcolumn:name="state",type=string,JSONPath=`.status.state`,description="State of the expansion" +kubebuilder:printcolumn:name="message",type=string,JSONPath=`.status.message`,description="Event message of the expansion" +kubebuilder:printcolumn:name="abort",type=boolean,JSONPath=`.spec.abort`,description="Abort the operation" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalVolumeConvert) DeepCopy ¶
func (in *LocalVolumeConvert) DeepCopy() *LocalVolumeConvert
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeConvert.
func (*LocalVolumeConvert) DeepCopyInto ¶
func (in *LocalVolumeConvert) DeepCopyInto(out *LocalVolumeConvert)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeConvert) DeepCopyObject ¶
func (in *LocalVolumeConvert) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeConvertList ¶
type LocalVolumeConvertList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalVolumeConvert `json:"items"` }
LocalVolumeConvertList contains a list of LocalVolumeConvert
func (*LocalVolumeConvertList) DeepCopy ¶
func (in *LocalVolumeConvertList) DeepCopy() *LocalVolumeConvertList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeConvertList.
func (*LocalVolumeConvertList) DeepCopyInto ¶
func (in *LocalVolumeConvertList) DeepCopyInto(out *LocalVolumeConvertList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeConvertList) DeepCopyObject ¶
func (in *LocalVolumeConvertList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeConvertSpec ¶
type LocalVolumeConvertSpec struct { VolumeName string `json:"volumeName,omitempty"` // ReplicaNumber is the number of replicas which the volume will be converted to // currently, only support the case of converting a non-HA volume to HA // +kubebuilder:validation:Minimum:=2 // +kubebuilder:validation:Maximum:=2 ReplicaNumber int64 `json:"replicaNumber,omitempty"` // +kubebuilder:default:=false Abort bool `json:"abort,omitempty"` }
LocalVolumeConvertSpec defines the desired state of LocalVolumeConvert
func (*LocalVolumeConvertSpec) DeepCopy ¶
func (in *LocalVolumeConvertSpec) DeepCopy() *LocalVolumeConvertSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeConvertSpec.
func (*LocalVolumeConvertSpec) DeepCopyInto ¶
func (in *LocalVolumeConvertSpec) DeepCopyInto(out *LocalVolumeConvertSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeConvertStatus ¶
type LocalVolumeConvertStatus struct { State State `json:"state,omitempty"` Message string `json:"message,omitempty"` }
LocalVolumeConvertStatus defines the observed state of LocalVolumeConvert
func (*LocalVolumeConvertStatus) DeepCopy ¶
func (in *LocalVolumeConvertStatus) DeepCopy() *LocalVolumeConvertStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeConvertStatus.
func (*LocalVolumeConvertStatus) DeepCopyInto ¶
func (in *LocalVolumeConvertStatus) DeepCopyInto(out *LocalVolumeConvertStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeExpand ¶
type LocalVolumeExpand struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalVolumeExpandSpec `json:"spec,omitempty"` Status LocalVolumeExpandStatus `json:"status,omitempty"` }
LocalVolumeExpand is the Schema for the localvolumeexpands API +kubebuilder:subresource:status +kubebuilder:resource:path=localvolumeexpands,scope=Cluster,shortName=lvexpand +kubebuilder:printcolumn:name="newCapacity",type=integer,JSONPath=`.spec.requiredCapacityBytes`,description="New capacity of the volume" +kubebuilder:printcolumn:name="abort",type=boolean,JSONPath=`.spec.abort`,description="Abort the operation" +kubebuilder:printcolumn:name="state",type=string,JSONPath=`.status.state`,description="State of the expansion" +kubebuilder:printcolumn:name="subs",type=string,JSONPath=`.status.subs`,description="Sub-operations on each volume replica expansion" +kubebuilder:printcolumn:name="message",type=string,JSONPath=`.status.message`,description="Event message of the expansion" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalVolumeExpand) AddSubs ¶
func (v *LocalVolumeExpand) AddSubs(subNames ...string)
AddSubs updates with subs info
func (*LocalVolumeExpand) DeepCopy ¶
func (in *LocalVolumeExpand) DeepCopy() *LocalVolumeExpand
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeExpand.
func (*LocalVolumeExpand) DeepCopyInto ¶
func (in *LocalVolumeExpand) DeepCopyInto(out *LocalVolumeExpand)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeExpand) DeepCopyObject ¶
func (in *LocalVolumeExpand) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*LocalVolumeExpand) HasSub ¶
func (v *LocalVolumeExpand) HasSub(name string) bool
HasSub updates with sub-resource info
type LocalVolumeExpandList ¶
type LocalVolumeExpandList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalVolumeExpand `json:"items"` }
LocalVolumeExpandList contains a list of LocalVolumeExpand
func (*LocalVolumeExpandList) DeepCopy ¶
func (in *LocalVolumeExpandList) DeepCopy() *LocalVolumeExpandList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeExpandList.
func (*LocalVolumeExpandList) DeepCopyInto ¶
func (in *LocalVolumeExpandList) DeepCopyInto(out *LocalVolumeExpandList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeExpandList) DeepCopyObject ¶
func (in *LocalVolumeExpandList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeExpandSpec ¶
type LocalVolumeExpandSpec struct { VolumeName string `json:"volumeName,omitempty"` // +kubebuilder:validation:Minimum:=4194304 RequiredCapacityBytes int64 `json:"requiredCapacityBytes,omitempty"` // +kubebuilder:default:=false Abort bool `json:"abort,omitempty"` }
LocalVolumeExpandSpec defines the desired state of LocalVolumeExpand
func (*LocalVolumeExpandSpec) DeepCopy ¶
func (in *LocalVolumeExpandSpec) DeepCopy() *LocalVolumeExpandSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeExpandSpec.
func (*LocalVolumeExpandSpec) DeepCopyInto ¶
func (in *LocalVolumeExpandSpec) DeepCopyInto(out *LocalVolumeExpandSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeExpandStatus ¶
type LocalVolumeExpandStatus struct { AllocatedCapacityBytes int64 `json:"allocatedCapacityBytes,omitempty"` // sub resources at different node. Subs []string `json:"subs,omitempty"` State State `json:"state,omitempty"` Message string `json:"message,omitempty"` }
LocalVolumeExpandStatus defines the observed state of LocalVolumeExpand
func (*LocalVolumeExpandStatus) DeepCopy ¶
func (in *LocalVolumeExpandStatus) DeepCopy() *LocalVolumeExpandStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeExpandStatus.
func (*LocalVolumeExpandStatus) DeepCopyInto ¶
func (in *LocalVolumeExpandStatus) DeepCopyInto(out *LocalVolumeExpandStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeGroup ¶
type LocalVolumeGroup struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalVolumeGroupSpec `json:"spec,omitempty"` Status LocalVolumeGroupStatus `json:"status,omitempty"` }
LocalVolumeGroup is the Schema for the localvolumegroups API +kubebuilder:subresource:status +kubebuilder:resource:path=localvolumegroups,scope=Cluster,shortName=lvg +kubebuilder:printcolumn:name="pod",type=string,JSONPath=`.spec.pods`,description="Name of associated pod" +kubebuilder:printcolumn:name="namespace",type=string,JSONPath=`.spec.namespace`,description="Namespace of associated pod" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalVolumeGroup) DeepCopy ¶
func (in *LocalVolumeGroup) DeepCopy() *LocalVolumeGroup
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroup.
func (*LocalVolumeGroup) DeepCopyInto ¶
func (in *LocalVolumeGroup) DeepCopyInto(out *LocalVolumeGroup)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeGroup) DeepCopyObject ¶
func (in *LocalVolumeGroup) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeGroupConvert ¶ added in v0.1.11
type LocalVolumeGroupConvert struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalVolumeGroupConvertSpec `json:"spec,omitempty"` Status LocalVolumeGroupConvertStatus `json:"status,omitempty"` }
LocalVolumeGroupConvert is the Schema for the localVolumeGroupConverts API +kubebuilder:subresource:status +kubebuilder:resource:path=localVolumeGroupConverts,scope=Cluster,shortName=lvconvert +kubebuilder:printcolumn:name="volume",type=string,JSONPath=`.spec.volumeName`,description="Name of the volume to convert" +kubebuilder:printcolumn:name="replicas",type=integer,JSONPath=`.spec.replicaNumber`,description="Number of volume replica" +kubebuilder:printcolumn:name="state",type=string,JSONPath=`.status.state`,description="State of the expansion" +kubebuilder:printcolumn:name="message",type=string,JSONPath=`.status.message`,description="Event message of the expansion" +kubebuilder:printcolumn:name="abort",type=boolean,JSONPath=`.spec.abort`,description="Abort the operation" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalVolumeGroupConvert) DeepCopy ¶ added in v0.1.11
func (in *LocalVolumeGroupConvert) DeepCopy() *LocalVolumeGroupConvert
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupConvert.
func (*LocalVolumeGroupConvert) DeepCopyInto ¶ added in v0.1.11
func (in *LocalVolumeGroupConvert) DeepCopyInto(out *LocalVolumeGroupConvert)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeGroupConvert) DeepCopyObject ¶ added in v0.1.11
func (in *LocalVolumeGroupConvert) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeGroupConvertList ¶ added in v0.1.11
type LocalVolumeGroupConvertList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalVolumeGroupConvert `json:"items"` }
LocalVolumeGroupConvertList contains a list of LocalVolumeGroupConvert
func (*LocalVolumeGroupConvertList) DeepCopy ¶ added in v0.1.11
func (in *LocalVolumeGroupConvertList) DeepCopy() *LocalVolumeGroupConvertList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupConvertList.
func (*LocalVolumeGroupConvertList) DeepCopyInto ¶ added in v0.1.11
func (in *LocalVolumeGroupConvertList) DeepCopyInto(out *LocalVolumeGroupConvertList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeGroupConvertList) DeepCopyObject ¶ added in v0.1.11
func (in *LocalVolumeGroupConvertList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeGroupConvertSpec ¶ added in v0.1.11
type LocalVolumeGroupConvertSpec struct { LocalVolumeGroupName string `json:"localVolumeGroupName,omitempty"` // ReplicaNumber is the number of replicas which the volume will be converted to // currently, only support the case of converting a non-HA volume to HA // +kubebuilder:validation:Minimum:=2 // +kubebuilder:validation:Maximum:=2 ReplicaNumber int64 `json:"replicaNumber,omitempty"` // +kubebuilder:default:=false Abort bool `json:"abort,omitempty"` }
LocalVolumeGroupConvertSpec defines the desired state of LocalVolumeGroupConvert
func (*LocalVolumeGroupConvertSpec) DeepCopy ¶ added in v0.1.11
func (in *LocalVolumeGroupConvertSpec) DeepCopy() *LocalVolumeGroupConvertSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupConvertSpec.
func (*LocalVolumeGroupConvertSpec) DeepCopyInto ¶ added in v0.1.11
func (in *LocalVolumeGroupConvertSpec) DeepCopyInto(out *LocalVolumeGroupConvertSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeGroupConvertStatus ¶ added in v0.1.11
type LocalVolumeGroupConvertStatus struct { State State `json:"state,omitempty"` Message string `json:"message,omitempty"` }
LocalVolumeGroupConvertStatus defines the observed state of LocalVolumeGroupConvert
func (*LocalVolumeGroupConvertStatus) DeepCopy ¶ added in v0.1.11
func (in *LocalVolumeGroupConvertStatus) DeepCopy() *LocalVolumeGroupConvertStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupConvertStatus.
func (*LocalVolumeGroupConvertStatus) DeepCopyInto ¶ added in v0.1.11
func (in *LocalVolumeGroupConvertStatus) DeepCopyInto(out *LocalVolumeGroupConvertStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeGroupList ¶
type LocalVolumeGroupList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalVolumeGroup `json:"items"` }
LocalVolumeGroupList contains a list of LocalVolumeGroup
func (*LocalVolumeGroupList) DeepCopy ¶
func (in *LocalVolumeGroupList) DeepCopy() *LocalVolumeGroupList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupList.
func (*LocalVolumeGroupList) DeepCopyInto ¶
func (in *LocalVolumeGroupList) DeepCopyInto(out *LocalVolumeGroupList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeGroupList) DeepCopyObject ¶
func (in *LocalVolumeGroupList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeGroupMigrate ¶ added in v0.1.10
type LocalVolumeGroupMigrate struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalVolumeGroupMigrateSpec `json:"spec,omitempty"` Status LocalVolumeGroupMigrateStatus `json:"status,omitempty"` }
LocalVolumeGroupMigrate is the Schema for the LocalVolumeGroupMigrates API +kubebuilder:subresource:status +kubebuilder:resource:path=LocalVolumeGroupMigrates,scope=Cluster,shortName=lvmigrate +kubebuilder:printcolumn:name="volume",type=string,JSONPath=`.spec.volumeName`,description="Name of the volume to be migrated" +kubebuilder:printcolumn:name="node",type=string,JSONPath=`.spec.nodeName`,description="Node name of the volume replica to be migrated" +kubebuilder:printcolumn:name="target",type=string,JSONPath=`.status.targetNodeName`,description="Node name of the new volume replica" +kubebuilder:printcolumn:name="state",type=string,JSONPath=`.status.state`,description="State of the migration" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalVolumeGroupMigrate) DeepCopy ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrate) DeepCopy() *LocalVolumeGroupMigrate
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupMigrate.
func (*LocalVolumeGroupMigrate) DeepCopyInto ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrate) DeepCopyInto(out *LocalVolumeGroupMigrate)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeGroupMigrate) DeepCopyObject ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrate) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeGroupMigrateList ¶ added in v0.1.10
type LocalVolumeGroupMigrateList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalVolumeGroupMigrate `json:"items"` }
LocalVolumeGroupMigrateList contains a list of LocalVolumeGroupMigrate
func (*LocalVolumeGroupMigrateList) DeepCopy ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrateList) DeepCopy() *LocalVolumeGroupMigrateList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupMigrateList.
func (*LocalVolumeGroupMigrateList) DeepCopyInto ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrateList) DeepCopyInto(out *LocalVolumeGroupMigrateList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeGroupMigrateList) DeepCopyObject ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrateList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeGroupMigrateSpec ¶ added in v0.1.10
type LocalVolumeGroupMigrateSpec struct { LocalVolumeGroupName string `json:"localVolumeGroupName"` // target NodeNames TargetNodesNames []string `json:"targetNodesNames"` // source NodeNames SourceNodesNames []string `json:"sourceNodesNames"` // +kubebuilder:default:=false Abort bool `json:"abort,omitempty"` }
LocalVolumeGroupMigrateSpec defines the desired state of LocalVolumeGroupMigrate
func (*LocalVolumeGroupMigrateSpec) DeepCopy ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrateSpec) DeepCopy() *LocalVolumeGroupMigrateSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupMigrateSpec.
func (*LocalVolumeGroupMigrateSpec) DeepCopyInto ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrateSpec) DeepCopyInto(out *LocalVolumeGroupMigrateSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeGroupMigrateStatus ¶ added in v0.1.10
type LocalVolumeGroupMigrateStatus struct { // record the volume's replica number, it will be set internally ReplicaNumber int64 `json:"replicaNumber,omitempty"` // record the node where the specified replica is migrated to TargetNodesNames []string `json:"targetNodesNames,omitempty"` // State of the operation, e.g. submitted, started, completed, abort, ... State State `json:"state,omitempty"` // error message to describe some states Message string `json:"message,omitempty"` }
LocalVolumeGroupMigrateStatus defines the observed state of LocalVolumeGroupMigrate
func (*LocalVolumeGroupMigrateStatus) DeepCopy ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrateStatus) DeepCopy() *LocalVolumeGroupMigrateStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupMigrateStatus.
func (*LocalVolumeGroupMigrateStatus) DeepCopyInto ¶ added in v0.1.10
func (in *LocalVolumeGroupMigrateStatus) DeepCopyInto(out *LocalVolumeGroupMigrateStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeGroupSpec ¶
type LocalVolumeGroupSpec struct { // Volumes is the collection of the volumes in the group Volumes []VolumeInfo `json:"volumes,omitempty"` // Accessibility is the topology requirement of the volume. It describes how to locate and distribute the volume replicas Accessibility AccessibilityTopology `json:"accessibility,omitempty"` Pods []string `json:"pods,omitempty"` }
LocalVolumeGroupSpec defines the desired state of LocalVolumeGroup
func (*LocalVolumeGroupSpec) DeepCopy ¶
func (in *LocalVolumeGroupSpec) DeepCopy() *LocalVolumeGroupSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupSpec.
func (*LocalVolumeGroupSpec) DeepCopyInto ¶
func (in *LocalVolumeGroupSpec) DeepCopyInto(out *LocalVolumeGroupSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeGroupStatus ¶
type LocalVolumeGroupStatus struct { }
LocalVolumeGroupStatus defines the observed state of LocalVolumeGroup
func (*LocalVolumeGroupStatus) DeepCopy ¶
func (in *LocalVolumeGroupStatus) DeepCopy() *LocalVolumeGroupStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeGroupStatus.
func (*LocalVolumeGroupStatus) DeepCopyInto ¶
func (in *LocalVolumeGroupStatus) DeepCopyInto(out *LocalVolumeGroupStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeList ¶
type LocalVolumeList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalVolume `json:"items"` }
LocalVolumeList contains a list of LocalVolume
func (*LocalVolumeList) DeepCopy ¶
func (in *LocalVolumeList) DeepCopy() *LocalVolumeList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeList.
func (*LocalVolumeList) DeepCopyInto ¶
func (in *LocalVolumeList) DeepCopyInto(out *LocalVolumeList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeList) DeepCopyObject ¶
func (in *LocalVolumeList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeMigrate ¶
type LocalVolumeMigrate struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalVolumeMigrateSpec `json:"spec,omitempty"` Status LocalVolumeMigrateStatus `json:"status,omitempty"` }
LocalVolumeMigrate is the Schema for the localvolumemigrates API +kubebuilder:subresource:status +kubebuilder:resource:path=localvolumemigrates,scope=Cluster,shortName=lvmigrate +kubebuilder:printcolumn:name="volume",type=string,JSONPath=`.spec.volumeName`,description="Name of the volume to be migrated" +kubebuilder:printcolumn:name="node",type=string,JSONPath=`.spec.nodeName`,description="Node name of the volume replica to be migrated" +kubebuilder:printcolumn:name="target",type=string,JSONPath=`.status.targetNodeName`,description="Node name of the new volume replica" +kubebuilder:printcolumn:name="state",type=string,JSONPath=`.status.state`,description="State of the migration" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalVolumeMigrate) DeepCopy ¶
func (in *LocalVolumeMigrate) DeepCopy() *LocalVolumeMigrate
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeMigrate.
func (*LocalVolumeMigrate) DeepCopyInto ¶
func (in *LocalVolumeMigrate) DeepCopyInto(out *LocalVolumeMigrate)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeMigrate) DeepCopyObject ¶
func (in *LocalVolumeMigrate) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeMigrateList ¶
type LocalVolumeMigrateList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalVolumeMigrate `json:"items"` }
LocalVolumeMigrateList contains a list of LocalVolumeMigrate
func (*LocalVolumeMigrateList) DeepCopy ¶
func (in *LocalVolumeMigrateList) DeepCopy() *LocalVolumeMigrateList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeMigrateList.
func (*LocalVolumeMigrateList) DeepCopyInto ¶
func (in *LocalVolumeMigrateList) DeepCopyInto(out *LocalVolumeMigrateList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeMigrateList) DeepCopyObject ¶
func (in *LocalVolumeMigrateList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeMigrateSpec ¶
type LocalVolumeMigrateSpec struct { VolumeName string `json:"volumeName"` NodeName string `json:"nodeName"` // +kubebuilder:default:=false Abort bool `json:"abort,omitempty"` }
LocalVolumeMigrateSpec defines the desired state of LocalVolumeMigrate
func (*LocalVolumeMigrateSpec) DeepCopy ¶
func (in *LocalVolumeMigrateSpec) DeepCopy() *LocalVolumeMigrateSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeMigrateSpec.
func (*LocalVolumeMigrateSpec) DeepCopyInto ¶
func (in *LocalVolumeMigrateSpec) DeepCopyInto(out *LocalVolumeMigrateSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeMigrateStatus ¶
type LocalVolumeMigrateStatus struct { // record the volume's replica number, it will be set internally ReplicaNumber int64 `json:"replicaNumber,omitempty"` // record the node where the specified replica is migrated to TargetNodeName string `json:"targetNodeName,omitempty"` // State of the operation, e.g. submitted, started, completed, abort, ... State State `json:"state,omitempty"` // error message to describe some states Message string `json:"message,omitempty"` }
LocalVolumeMigrateStatus defines the observed state of LocalVolumeMigrate
func (*LocalVolumeMigrateStatus) DeepCopy ¶
func (in *LocalVolumeMigrateStatus) DeepCopy() *LocalVolumeMigrateStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeMigrateStatus.
func (*LocalVolumeMigrateStatus) DeepCopyInto ¶
func (in *LocalVolumeMigrateStatus) DeepCopyInto(out *LocalVolumeMigrateStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeReplica ¶
type LocalVolumeReplica struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec LocalVolumeReplicaSpec `json:"spec,omitempty"` Status LocalVolumeReplicaStatus `json:"status,omitempty"` }
LocalVolumeReplica is the Schema for the volumereplicas API +kubebuilder:subresource:status +kubebuilder:resource:path=localvolumereplicas,scope=Cluster,shortName=lvr +kubebuilder:printcolumn:name="capacity",type=integer,JSONPath=`.spec.requiredCapacityBytes`,description="Required capacity of the volume replica" +kubebuilder:printcolumn:name="node",type=string,JSONPath=`.spec.nodeName`,description="Node name where the volume replica is located at" +kubebuilder:printcolumn:name="state",type=string,JSONPath=`.status.state`,description="State of the volume replica" +kubebuilder:printcolumn:name="synced",type=boolean,JSONPath=`.status.synced`,description="Sync status of the volume replica" +kubebuilder:printcolumn:name="device",type=string,JSONPath=`.status.devPath`,description="Device path of the volume replica" +kubebuilder:printcolumn:name="age",type=date,JSONPath=`.metadata.creationTimestamp`
func (*LocalVolumeReplica) DeepCopy ¶
func (in *LocalVolumeReplica) DeepCopy() *LocalVolumeReplica
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeReplica.
func (*LocalVolumeReplica) DeepCopyInto ¶
func (in *LocalVolumeReplica) DeepCopyInto(out *LocalVolumeReplica)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeReplica) DeepCopyObject ¶
func (in *LocalVolumeReplica) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeReplicaList ¶
type LocalVolumeReplicaList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []LocalVolumeReplica `json:"items"` }
LocalVolumeReplicaList contains a list of LocalVolumeReplica
func (*LocalVolumeReplicaList) DeepCopy ¶
func (in *LocalVolumeReplicaList) DeepCopy() *LocalVolumeReplicaList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeReplicaList.
func (*LocalVolumeReplicaList) DeepCopyInto ¶
func (in *LocalVolumeReplicaList) DeepCopyInto(out *LocalVolumeReplicaList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*LocalVolumeReplicaList) DeepCopyObject ¶
func (in *LocalVolumeReplicaList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type LocalVolumeReplicaSpec ¶
type LocalVolumeReplicaSpec struct { // VolumeName is the name of the volume, e.g. pvc-fbf3ffc3-66db-4dae-9032-bda3c61b8f85 VolumeName string `json:"volumeName,omitempty"` // PoolName is the name of the storage pool, e.g. LocalStorage_PoolHDD, LocalStorage_PoolSSD, etc.. PoolName string `json:"poolName,omitempty"` // NodeName is the assigned node where the volume replica is located NodeName string `json:"nodeName,omitempty"` // +kubebuilder:validation:Minimum:=4194304 RequiredCapacityBytes int64 `json:"requiredCapacityBytes,omitempty"` // Delete is to indicate where the replica should be deleted or not. // It's different from the regular resource delete interface in Kubernetes. // The purpose is to protect it from any mistakes // +kubebuilder:default:=false Delete bool `json:"delete,omitempty"` }
LocalVolumeReplicaSpec defines the desired state of LocalVolumeReplica
func (*LocalVolumeReplicaSpec) DeepCopy ¶
func (in *LocalVolumeReplicaSpec) DeepCopy() *LocalVolumeReplicaSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeReplicaSpec.
func (*LocalVolumeReplicaSpec) DeepCopyInto ¶
func (in *LocalVolumeReplicaSpec) DeepCopyInto(out *LocalVolumeReplicaSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeReplicaStatus ¶
type LocalVolumeReplicaStatus struct { // StoragePath is a real path of the volume replica, like /dev/sdg. StoragePath string `json:"storagePath,omitempty"` // DevicePath is a link path of the StoragePath of the volume replica, // e.g. /dev/LocalStorage_PoolHDD/pvc-fbf3ffc3-66db-4dae-9032-bda3c61b8f85 DevicePath string `json:"devPath,omitempty"` // Disks is a list of physical disks where the volume replica is spread cross, especially for striped LVM volume replica Disks []string `json:"disks,omitempty"` // AllocatedCapacityBytes is the real allocated capacity in bytes AllocatedCapacityBytes int64 `json:"allocatedCapacityBytes,omitempty"` // State is the phase of volume replica, e.g. Creating, Ready, NotReady, ToBeDeleted, Deleted State State `json:"state,omitempty"` // Synced is the sync state of the volume replica, which is important in HA volume // +kubebuilder:default:=false Synced bool `json:"synced,omitempty"` // HAState is state for ha replica, replica.Status.State == Ready only when HAState is Consistent of nil HAState *HAState `json:"haState,omitempty"` // InUse is one of volume replica's states, which indicates the replica is used by a Pod or not // +kubebuilder:default:=false InUse bool `json:"inuse,omitempty"` }
LocalVolumeReplicaStatus defines the observed state of LocalVolumeReplica
func (*LocalVolumeReplicaStatus) DeepCopy ¶
func (in *LocalVolumeReplicaStatus) DeepCopy() *LocalVolumeReplicaStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeReplicaStatus.
func (*LocalVolumeReplicaStatus) DeepCopyInto ¶
func (in *LocalVolumeReplicaStatus) DeepCopyInto(out *LocalVolumeReplicaStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeSpec ¶
type LocalVolumeSpec struct { // +kubebuilder:validation:Minimum:=4194304 RequiredCapacityBytes int64 `json:"requiredCapacityBytes,omitempty"` // PoolName is the name of the storage pool, e.g. LocalStorage_PoolHDD, LocalStorage_PoolSSD, etc.. PoolName string `json:"poolName,omitempty"` // replica number: 1 - non-HA, 2 - HA, 3 - migration (temp) // +kubebuilder:validation:Minimum:=1 // +kubebuilder:validation:Maximum:=3 ReplicaNumber int64 `json:"replicaNumber,omitempty"` // Convertible is to indicate if the non-HA volume can be transitted to HA volume or not // +kubebuilder:default:=false Convertible bool `json:"convertible,omitempty"` // Accessibility is the topology requirement of the volume. It describes how to locate and distribute the volume replicas Accessibility AccessibilityTopology `json:"accessibility,omitempty"` // PersistentVolumeClaimNamespace is the namespace of the associated PVC PersistentVolumeClaimNamespace string `json:"pvcNamespace,omitempty"` // PersistentVolumeClaimName is the name of the associated PVC PersistentVolumeClaimName string `json:"pvcName,omitempty"` // VolumeGroup is the group name of the local volumes. It is designed for the scheduling and allocating. VolumeGroup string `json:"volumegroup,omitempty"` // Config is the configration for the volume replicas // It will be managed by the controller, and watched by all the nodes // Important: node will manage volume replica according this config Config *VolumeConfig `json:"config,omitempty"` // Delete is to indicate where the replica should be deleted or not. // It's different from the regular resource delete interface in Kubernetes. // The purpose is to protect it from any mistakes // +kubebuilder:default:=false Delete bool `json:"delete,omitempty"` }
LocalVolumeSpec defines the desired state of LocalVolume
func (*LocalVolumeSpec) DeepCopy ¶
func (in *LocalVolumeSpec) DeepCopy() *LocalVolumeSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeSpec.
func (*LocalVolumeSpec) DeepCopyInto ¶
func (in *LocalVolumeSpec) DeepCopyInto(out *LocalVolumeSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type LocalVolumeStatus ¶
type LocalVolumeStatus struct { // AllocatedCapacityBytes is the real allocated capacity in bytes of the volume replicas. // In case of HA volume with multiple replicas, the value is equal to the one of a replica's size AllocatedCapacityBytes int64 `json:"allocatedCapacityBytes,omitempty"` // Volume is a logical concept and composed by one or many replicas which will be located at different node. Replicas []string `json:"replicas,omitempty"` // State is the phase of volume replica, e.g. Creating, Ready, NotReady, ToBeDeleted, Deleted State State `json:"state,omitempty"` // PublishedNodeName is the node where the volume is published and used by pod PublishedNodeName string `json:"publishedNode,omitempty"` }
LocalVolumeStatus defines the observed state of LocalVolume
func (*LocalVolumeStatus) DeepCopy ¶
func (in *LocalVolumeStatus) DeepCopy() *LocalVolumeStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocalVolumeStatus.
func (*LocalVolumeStatus) DeepCopyInto ¶
func (in *LocalVolumeStatus) DeepCopyInto(out *LocalVolumeStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type NodeConfig ¶
type NodeConfig struct { Name string `json:"name,omitempty"` StorageIP string `json:"ip,omitempty"` Topology *Topology `json:"topology,omitempty"` }
NodeConfig defines local storage system configurations
func (*NodeConfig) DeepCopy ¶
func (in *NodeConfig) DeepCopy() *NodeConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeConfig.
func (*NodeConfig) DeepCopyInto ¶
func (in *NodeConfig) DeepCopyInto(out *NodeConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SystemConfig ¶
type SystemConfig struct { Mode SystemMode `json:"mode"` DRBD *DRBDSystemConfig `json:"drbd"` MaxHAVolumeCount int `json:"maxVolumeCount"` }
SystemConfig is volume HA related system configuration
func (*SystemConfig) DeepCopy ¶
func (in *SystemConfig) DeepCopy() *SystemConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SystemConfig.
func (*SystemConfig) DeepCopyInto ¶
func (in *SystemConfig) DeepCopyInto(out *SystemConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type SystemMode ¶
type SystemMode string
SystemMode of HA module
var (
SystemModeDRBD SystemMode = "drbd"
)
misc
type Topology ¶
type Topology struct { // Zone is a collection of Local Storage Nodes // +kubebuilder:default:=default Zone string `json:"zone,omitempty"` // Region is a collection of Zones // +kubebuilder:default:=default Region string `json:"region,omitempty"` }
Topology defines the topology info of Node
func (*Topology) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Topology.
func (*Topology) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type VolumeConfig ¶
type VolumeConfig struct { // Version of config, start from 0, plus 1 every time config update Version int `json:"version"` VolumeName string `json:"volumeName"` RequiredCapacityBytes int64 `json:"requiredCapacityBytes,omitempty"` // Convertible is to indicate if the non-HA volume can be transitted to HA volume or not Convertible bool `json:"convertible,omitempty"` // ResourceID is for HA volume, set to '-1' for non-HA volume ResourceID int `json:"resourceID"` ReadyToInitialize bool `json:"readyToInitialize"` Initialized bool `json:"initialized"` Replicas []VolumeReplica `json:"replicas"` }
VolumeConfig is the configration of the volume, including the replicas
func (*VolumeConfig) DeepCopy ¶
func (in *VolumeConfig) DeepCopy() *VolumeConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VolumeConfig.
func (*VolumeConfig) DeepCopyInto ¶
func (in *VolumeConfig) DeepCopyInto(out *VolumeConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*VolumeConfig) DeepEqual ¶
func (vc *VolumeConfig) DeepEqual(peer *VolumeConfig) bool
DeepEqual check if the two configs are equal completely or not
type VolumeGroupManager ¶ added in v0.1.8
type VolumeGroupManager interface { Init(stopCh <-chan struct{}) ReconcileVolumeGroup(volGroup *LocalVolumeGroup) GetLocalVolumeGroupByName(nameSpace, lvgName string) (*LocalVolumeGroup, error) GetLocalVolumeGroupByLocalVolume(nameSpace, lvName string) (*LocalVolumeGroup, error) GetLocalVolumeGroupByPVC(pvcName string, pvcNamespace string) (*LocalVolumeGroup, error) }
type VolumeInfo ¶ added in v0.1.8
type VolumeInfo struct { // LocalVolumeName is the name of the LocalVolume LocalVolumeName string `json:"localvolume,omitempty"` // PersistentVolumeClaimName is the name of the associated PVC PersistentVolumeClaimName string `json:"pvc,omitempty"` }
func (*VolumeInfo) DeepCopy ¶ added in v0.1.8
func (in *VolumeInfo) DeepCopy() *VolumeInfo
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VolumeInfo.
func (*VolumeInfo) DeepCopyInto ¶ added in v0.1.8
func (in *VolumeInfo) DeepCopyInto(out *VolumeInfo)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type VolumeReplica ¶
type VolumeReplica struct { ID int `json:"id"` Hostname string `json:"hostname"` IP string `json:"ip"` Primary bool `json:"primary"` }
VolumeReplica contains informations of replica peer
func (*VolumeReplica) DeepCopy ¶
func (in *VolumeReplica) DeepCopy() *VolumeReplica
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VolumeReplica.
func (*VolumeReplica) DeepCopyInto ¶
func (in *VolumeReplica) DeepCopyInto(out *VolumeReplica)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*VolumeReplica) DeepEqual ¶
func (vr *VolumeReplica) DeepEqual(peer *VolumeReplica) bool
DeepEqual check if the two volumereplicas are equal completely or not
type VolumeScheduler ¶ added in v0.1.9
type VolumeScheduler interface { Init() // schedule will schedule all replicas, and generate a valid VolumeConfig Allocate(vol *LocalVolume) (*VolumeConfig, error) GetNodeCandidates(vols []*LocalVolume) []*LocalStorageNode }
VolumeScheduler interface
Source Files ¶
- doc.go
- group.go
- localstoragenode_types.go
- localvolume_types.go
- localvolumeconvert_types.go
- localvolumeexpand_types.go
- localvolumegroup_types.go
- localvolumegroupconvert_types.go
- localvolumegroupmigrate_types.go
- localvolumemigrate_types.go
- localvolumereplica_types.go
- register.go
- types.go
- zz_generated.deepcopy.go