Documentation ¶
Index ¶
Constants ¶
const ( // LinstorNodeKey refers to a node running the LINSTOR csi node service // and the linstor Satellite and is therefore capable of hosting LINSTOR volumes. LinstorNodeKey = "linbit.com/hostname" // LinstorStoragePoolKeyPrefix is the prefix used when specifying the available storage // pools on a node via CSI topology keys. LinstorStoragePoolKeyPrefix = "linbit.com" // The value assigned to the storage pool label, given that the node has access to the storage pool. LinstorStoragePoolValue = "true" )
Variables ¶
This section is empty.
Functions ¶
func ToStoragePoolLabel ¶ added in v0.10.0
Converts the storage pool name into a CSI Topology compatible label.
There is an upper limit on the length of these keys (63 chars for prefix + 63 chars for the key) as per CSI Spec. LINSTOR enforces a stricter limit of 48 characters for storage pools, so this should not be an issue.
Types ¶
type PlacementPolicy ¶
type PlacementPolicy int
PlacementPolicy determines which scheduler will create volumes and report their accessible topology.
const ( // Unknown placement policy Unknown PlacementPolicy = iota // Manual place volumes with a list of nodes and clients. Manual // AutoPlace volumes using linstor's built in autoplace feature. AutoPlace // FollowTopology place volumes local to topology preferences, in order // of those preferences. FollowTopology // BalancedTopology places remote volumes in the same zone(Rack) // and pick Node, StoragePool, PrefNic based on utilization Balanced )
func PlacementPolicyString ¶
func PlacementPolicyString(s string) (PlacementPolicy, error)
PlacementPolicyString retrieves an enum value from the enum constants string name. Throws an error if the param is not part of the enum.
func PlacementPolicyValues ¶
func PlacementPolicyValues() []PlacementPolicy
PlacementPolicyValues returns all values of the enum
func (PlacementPolicy) IsAPlacementPolicy ¶
func (i PlacementPolicy) IsAPlacementPolicy() bool
IsAPlacementPolicy returns "true" if the value is listed in the enum definition. "false" otherwise
func (PlacementPolicy) String ¶
func (i PlacementPolicy) String() string