final case class CSIStorageCapacity(storageClassName: String, maximumVolumeSize: Option[Quantity] = None, nodeTopology: Option[LabelSelector] = None, metadata: Option[ObjectMeta] = None, capacity: Option[Quantity] = None) extends KObject with Product with Serializable
CSIStorageCapacity stores the result of one CSI GetCapacity call. For a given StorageClass, this describes the available capacity in a particular topology segment. This can be used when considering where to instantiate new PersistentVolumes.
For example this can express things like: - StorageClass "standard" has "1234 GiB" available in "topology.kubernetes.io/zone=us-east1" - StorageClass "localssd" has "10 GiB" available in "kubernetes.io/hostname=knode-abc123"
The following three cases all imply that no capacity is available for a certain combination: - no object exists with suitable topology and storage class name - such an object exists, but the capacity is unset - such an object exists, but the capacity is zero
The producer of these objects can decide which approach is more suitable.
They are consumed by the kube-scheduler when a CSI driver opts into capacity-aware scheduling with CSIDriverSpec.StorageCapacity. The scheduler compares the MaximumVolumeSize against the requested size of pending volumes to filter out unsuitable nodes. If MaximumVolumeSize is unset, it falls back to a comparison against the less precise Capacity. If that is also unset, the scheduler assumes that capacity is insufficient and tries some other node.
- Source
- CSIStorageCapacity.scala
- Alphabetic
- By Inheritance
- CSIStorageCapacity
- KObject
- Product
- Equals
- Serializable
- Serializable
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new CSIStorageCapacity(storageClassName: String, maximumVolumeSize: Option[Quantity] = None, nodeTopology: Option[LabelSelector] = None, metadata: Option[ObjectMeta] = None, capacity: Option[Quantity] = None)
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
val
_resourceKind: ResourceKind
- Attributes
- protected
- Definition Classes
- CSIStorageCapacity → KObject
-
final
lazy val
apiVersion: String
- Definition Classes
- KObject
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- val capacity: Option[Quantity]
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
group: String
- Definition Classes
- KObject
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
lazy val
kind: String
- Definition Classes
- KObject
- val maximumVolumeSize: Option[Quantity]
- val metadata: Option[ObjectMeta]
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- val nodeTopology: Option[LabelSelector]
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- val storageClassName: String
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
final
lazy val
version: String
- Definition Classes
- KObject
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
- def withCapacity(value: Quantity): CSIStorageCapacity
- def withMaximumVolumeSize(value: Quantity): CSIStorageCapacity
- def withMetadata(value: ObjectMeta): CSIStorageCapacity
- def withNodeTopology(value: LabelSelector): CSIStorageCapacity
- def withStorageClassName(value: String): CSIStorageCapacity