Class V1CapacityRequirements
CapacityRequirements defines the capacity requirements for a specific device
request.
Inheritance
V1CapacityRequirements
Assembly: KubernetesClient.dll
Syntax
public record V1CapacityRequirements : IEquatable<V1CapacityRequirements>
Constructors
View Source
V1CapacityRequirements()
Declaration
public V1CapacityRequirements()
View Source
V1CapacityRequirements(V1CapacityRequirements)
Declaration
protected V1CapacityRequirements(V1CapacityRequirements original)
Parameters
Properties
View Source
EqualityContract
Declaration
protected virtual Type EqualityContract { get; }
Property Value
View Source
Requests
Requests represent individual device resource requests for distinct resources,
all of which must be provided by the device.
This value is used as an additional filtering condition against the available
capacity on the device. This is semantically equivalent to a CEL selector with
device.capacity[<domain>].<name>.compareTo(quantity(<request quantity>)) >= 0.
For example,
device.capacity['test-driver.cdi.k8s.io'].counters.compareTo(quantity('2')) >=
0.
When a requestPolicy is defined, the requested amount is adjusted upward to the
nearest valid value based on the policy. If the requested amount cannot be
adjusted to a valid value—because it exceeds what the requestPolicy allows— the
device is considered ineligible for allocation.
For any capacity that is not explicitly requested: - If no requestPolicy is set,
the default consumed capacity is equal to the full device capacity
(i.e., the whole device is claimed).
- If a requestPolicy is set, the default consumed capacity is determined
according to that policy.
If the device allows multiple allocation, the aggregated amount across all
requests must not exceed the capacity value. The consumed capacity, which may be
adjusted based on the requestPolicy if defined, is recorded in the resource
claim’s status.devices[*].consumedCapacity field.
Declaration
[JsonPropertyName("requests")]
public IDictionary<string, ResourceQuantity> Requests { get; set; }
Property Value
Methods
View Source
Equals(object?)
Declaration
public override bool Equals(object? obj)
Parameters
| Type |
Name |
Description |
| object |
obj |
|
Returns
Overrides
View Source
Equals(V1CapacityRequirements?)
Declaration
public virtual bool Equals(V1CapacityRequirements? other)
Parameters
Returns
View Source
GetHashCode()
Declaration
public override int GetHashCode()
Returns
Overrides
View Source
PrintMembers(StringBuilder)
Declaration
protected virtual bool PrintMembers(StringBuilder builder)
Parameters
Returns
View Source
ToString()
Declaration
public override string ToString()
Returns
Overrides
Operators
View Source
operator ==(V1CapacityRequirements?, V1CapacityRequirements?)
Declaration
public static bool operator ==(V1CapacityRequirements? left, V1CapacityRequirements? right)
Parameters
Returns
View Source
operator !=(V1CapacityRequirements?, V1CapacityRequirements?)
Declaration
public static bool operator !=(V1CapacityRequirements? left, V1CapacityRequirements? right)
Parameters
Returns
Implements