Defines a "io.k8s.api.storage.v1alpha1.CSIStorageCapacity" API object
the scope in which to define this object
a scope-local name for the object
The group portion of the API version (e.g.
The object's API version (e.g.
The chart in which this object is defined.
The object kind.
Metadata associated with this API object.
The name of the API object.
If a name is specified in
metadata.name this will be the name returned.
Otherwise, a name will be generated by calling
Chart.of(this).generatedObjectName(this), which by default uses the
construct path to generate a DNS-compatible name for the resource.
The tree node.
Returns the apiVersion and kind for "io.k8s.api.storage.v1alpha1.CSIStorageCapacity"
Create a dependency between this ApiObject and other constructs. These can be other ApiObjects, Charts, or custom.
the dependencies to add.
Applies a set of RFC-6902 JSON-Patch operations to the manifest synthesized for this API object.
The JSON-Patch operations to apply.
Renders the object to Kubernetes JSON.
Returns a string representation of this construct.
x is a construct.
Use this method instead of
instanceof to properly detect
instances, even when the construct library is symlinked.
constructs library on
disk are seen as independent, completely different libraries. As a
consequence, the class
Construct in each copy of the
is seen as a different class, and an instance of one class will not test as
instanceof the other class.
npm install will not create installations
like this, but users may manually symlink construct libraries together or
use a monorepo tool: in those cases, multiple copies of the
library can be accidentally installed, and
instanceof will behave
unpredictably. It is safest to avoid using
instanceof, and using
this type-testing method instead.
x is an object created from a class which extends
Renders a Kubernetes manifest for "io.k8s.api.storage.v1alpha1.CSIStorageCapacity".
This can be used to inline resource manifests inside other objects (e.g. as templates).
Resource which is a child of the given
c is an
ApiObject, it is returned directly. Throws an
exception if the construct does not have a child named
Default or if
this child is not an
The higher-level construct
Generated using TypeDoc
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 if the CSIStorageCapacity beta feature gate is enabled there and a CSI driver opts into capacity-aware scheduling with CSIDriver.StorageCapacity.