updated vendor
This commit is contained in:
+1318
File diff suppressed because it is too large
Load Diff
+219
-1
@@ -120,11 +120,21 @@ message DeviceTaint {
|
||||
// Consumers must treat unknown effects like None.
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
optional string effect = 3;
|
||||
|
||||
// TimeAdded represents the time at which the taint was added.
|
||||
// TimeAdded represents the time at which the taint was added or
|
||||
// (only in a DeviceTaintRule) the effect was modified.
|
||||
// Added automatically during create or update if not set.
|
||||
//
|
||||
// In addition, in a DeviceTaintRule a value provided during
|
||||
// an update gets replaced with the current time if the provided
|
||||
// value is the same as the old one and the new effect is different.
|
||||
// Changing the key and/or value while keeping the effect unchanged
|
||||
// is possible and does not update the time stamp because the eviction
|
||||
// which uses it is either already started (NoExecute) or
|
||||
// not started yet (NoEffect, NoSchedule).
|
||||
//
|
||||
// +optional
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.Time timeAdded = 4;
|
||||
}
|
||||
@@ -140,6 +150,7 @@ message DeviceTaintRule {
|
||||
// Spec specifies the selector and one taint.
|
||||
//
|
||||
// Changing the spec automatically increments the metadata.generation number.
|
||||
// +required
|
||||
optional DeviceTaintRuleSpec spec = 2;
|
||||
|
||||
// Status provides information about what was requested in the spec.
|
||||
@@ -237,3 +248,210 @@ message DeviceTaintSelector {
|
||||
optional string device = 4;
|
||||
}
|
||||
|
||||
// PoolStatus contains status information for a single resource pool.
|
||||
message PoolStatus {
|
||||
// Driver is the DRA driver name for this pool.
|
||||
// Must be a DNS subdomain (e.g., "gpu.example.com").
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:format=k8s-long-name-caseless
|
||||
optional string driver = 1;
|
||||
|
||||
// PoolName is the name of the pool.
|
||||
// Must be a valid resource pool name (DNS subdomains separated by "/").
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:format=k8s-resource-pool-name
|
||||
optional string poolName = 2;
|
||||
|
||||
// Generation is the pool generation observed across all ResourceSlices
|
||||
// in this pool. Only the latest generation is reported. During a generation
|
||||
// rollout, if not all slices at the latest generation have been published,
|
||||
// the pool is included with a validationError and device counts unset.
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:minimum=0
|
||||
optional int64 generation = 9;
|
||||
|
||||
// ResourceSliceCount is the number of ResourceSlices that make up this pool.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=1
|
||||
optional int32 resourceSliceCount = 8;
|
||||
|
||||
// TotalDevices is the total number of devices in the pool across all slices.
|
||||
// A value of 0 means the pool has no devices.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=0
|
||||
optional int32 totalDevices = 4;
|
||||
|
||||
// AllocatedDevices is the number of devices currently allocated to claims.
|
||||
// A value of 0 means no devices are allocated.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=0
|
||||
optional int32 allocatedDevices = 5;
|
||||
|
||||
// AvailableDevices is the number of devices available for allocation.
|
||||
// This equals TotalDevices - AllocatedDevices - UnavailableDevices.
|
||||
// A value of 0 means no devices are currently available.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=0
|
||||
optional int32 availableDevices = 6;
|
||||
|
||||
// UnavailableDevices is the number of devices that are not available
|
||||
// due to taints or other conditions, but are not allocated.
|
||||
// A value of 0 means all unallocated devices are available.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=0
|
||||
optional int32 unavailableDevices = 7;
|
||||
|
||||
// NodeName is the node this pool is associated with.
|
||||
// When omitted, the pool is not associated with a specific node.
|
||||
// Must be a valid DNS subdomain name (RFC1123).
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:format=k8s-long-name
|
||||
optional string nodeName = 3;
|
||||
|
||||
// ValidationError is set when the pool's data could not be fully
|
||||
// validated (e.g., incomplete slice publication). When set, device
|
||||
// count fields and ResourceSliceCount may be unset.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:maxBytes=256
|
||||
optional string validationError = 10;
|
||||
}
|
||||
|
||||
// ResourcePoolStatusRequest triggers a one-time calculation of resource pool status
|
||||
// based on the provided filters. Once status is set, the request is considered complete and will not be reprocessed.
|
||||
// Users should delete and recreate requests to get updated information.
|
||||
message ResourcePoolStatusRequest {
|
||||
// Standard object metadata
|
||||
// +required
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
|
||||
|
||||
// Spec defines the filters for which pools to include in the status.
|
||||
// The spec is immutable once created.
|
||||
//
|
||||
// +required
|
||||
// +k8s:immutable
|
||||
optional ResourcePoolStatusRequestSpec spec = 2;
|
||||
|
||||
// Status is populated by the controller with the calculated pool status.
|
||||
// When status is non-nil, the request is considered complete and the
|
||||
// entire object becomes immutable.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
optional ResourcePoolStatusRequestStatus status = 3;
|
||||
}
|
||||
|
||||
// ResourcePoolStatusRequestList is a collection of ResourcePoolStatusRequests.
|
||||
message ResourcePoolStatusRequestList {
|
||||
// Standard list metadata
|
||||
// +optional
|
||||
optional .k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1;
|
||||
|
||||
// Items is the list of ResourcePoolStatusRequests.
|
||||
repeated ResourcePoolStatusRequest items = 2;
|
||||
}
|
||||
|
||||
// ResourcePoolStatusRequestSpec defines the filters for the pool status request.
|
||||
message ResourcePoolStatusRequestSpec {
|
||||
// Driver specifies the DRA driver name to filter pools.
|
||||
// Only pools from ResourceSlices with this driver will be included.
|
||||
// Must be a DNS subdomain (e.g., "gpu.example.com").
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:format=k8s-long-name-caseless
|
||||
optional string driver = 1;
|
||||
|
||||
// PoolName optionally filters to a specific pool name.
|
||||
// If not specified, all pools from the specified driver are included.
|
||||
// When specified, must be a non-empty valid resource pool name
|
||||
// (DNS subdomains separated by "/").
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:format=k8s-resource-pool-name
|
||||
optional string poolName = 2;
|
||||
|
||||
// Limit optionally specifies the maximum number of pools to return in the status.
|
||||
// If more pools match the filter criteria, the response will be truncated
|
||||
// (i.e., len(status.pools) < status.poolCount).
|
||||
//
|
||||
// Default: 100
|
||||
// Minimum: 1
|
||||
// Maximum: 1000
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +default=100
|
||||
// +k8s:minimum=1
|
||||
// +k8s:maximum=1000
|
||||
optional int32 limit = 3;
|
||||
}
|
||||
|
||||
// ResourcePoolStatusRequestStatus contains the calculated pool status information.
|
||||
message ResourcePoolStatusRequestStatus {
|
||||
// PoolCount is the total number of pools that matched the filter criteria,
|
||||
// regardless of truncation. This helps users understand how many pools exist
|
||||
// even when the response is truncated. A value of 0 means no pools matched
|
||||
// the filter criteria.
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:minimum=0
|
||||
optional int32 poolCount = 6;
|
||||
|
||||
// Pools contains the first `spec.limit` matching pools, sorted by driver
|
||||
// then pool name. If `len(pools) < poolCount`, the list was truncated.
|
||||
// When omitted, no pools matched the request filters.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +listType=atomic
|
||||
// +k8s:listType=atomic
|
||||
// +k8s:maxItems=1000
|
||||
repeated PoolStatus pools = 2;
|
||||
|
||||
// Conditions provide information about the state of the request.
|
||||
// A condition with type=Complete or type=Failed will always be set
|
||||
// when the status is populated.
|
||||
//
|
||||
// Known condition types:
|
||||
// - "Complete": True when the request has been processed successfully
|
||||
// - "Failed": True when the request could not be processed
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +listType=map
|
||||
// +k8s:listType=map
|
||||
// +listMapKey=type
|
||||
// +k8s:listMapKey=type
|
||||
// +patchStrategy=merge
|
||||
// +patchMergeKey=type
|
||||
// +k8s:maxItems=10
|
||||
repeated .k8s.io.apimachinery.pkg.apis.meta.v1.Condition conditions = 3;
|
||||
}
|
||||
|
||||
|
||||
-38
@@ -1,38 +0,0 @@
|
||||
//go:build kubernetes_protomessage_one_more_release
|
||||
// +build kubernetes_protomessage_one_more_release
|
||||
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by go-to-protobuf. DO NOT EDIT.
|
||||
|
||||
package v1alpha3
|
||||
|
||||
func (*CELDeviceSelector) ProtoMessage() {}
|
||||
|
||||
func (*DeviceSelector) ProtoMessage() {}
|
||||
|
||||
func (*DeviceTaint) ProtoMessage() {}
|
||||
|
||||
func (*DeviceTaintRule) ProtoMessage() {}
|
||||
|
||||
func (*DeviceTaintRuleList) ProtoMessage() {}
|
||||
|
||||
func (*DeviceTaintRuleSpec) ProtoMessage() {}
|
||||
|
||||
func (*DeviceTaintRuleStatus) ProtoMessage() {}
|
||||
|
||||
func (*DeviceTaintSelector) ProtoMessage() {}
|
||||
+2
@@ -46,6 +46,8 @@ func addKnownTypes(scheme *runtime.Scheme) error {
|
||||
scheme.AddKnownTypes(SchemeGroupVersion,
|
||||
&DeviceTaintRule{},
|
||||
&DeviceTaintRuleList{},
|
||||
&ResourcePoolStatusRequest{},
|
||||
&ResourcePoolStatusRequestList{},
|
||||
)
|
||||
|
||||
// Add the watch version that applies
|
||||
|
||||
+243
-1
@@ -140,6 +140,7 @@ type DeviceTaint struct {
|
||||
// Consumers must treat unknown effects like None.
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
Effect DeviceTaintEffect `json:"effect" protobuf:"bytes,3,name=effect,casttype=DeviceTaintEffect"`
|
||||
|
||||
// ^^^^
|
||||
@@ -155,9 +156,18 @@ type DeviceTaint struct {
|
||||
// which will enable adding new enums within a single release without
|
||||
// ratcheting.
|
||||
|
||||
// TimeAdded represents the time at which the taint was added.
|
||||
// TimeAdded represents the time at which the taint was added or
|
||||
// (only in a DeviceTaintRule) the effect was modified.
|
||||
// Added automatically during create or update if not set.
|
||||
//
|
||||
// In addition, in a DeviceTaintRule a value provided during
|
||||
// an update gets replaced with the current time if the provided
|
||||
// value is the same as the old one and the new effect is different.
|
||||
// Changing the key and/or value while keeping the effect unchanged
|
||||
// is possible and does not update the time stamp because the eviction
|
||||
// which uses it is either already started (NoExecute) or
|
||||
// not started yet (NoEffect, NoSchedule).
|
||||
//
|
||||
// +optional
|
||||
TimeAdded *metav1.Time `json:"timeAdded,omitempty" protobuf:"bytes,4,opt,name=timeAdded"`
|
||||
|
||||
@@ -169,6 +179,7 @@ type DeviceTaint struct {
|
||||
}
|
||||
|
||||
// +enum
|
||||
// +k8s:enum
|
||||
type DeviceTaintEffect string
|
||||
|
||||
const (
|
||||
@@ -201,6 +212,7 @@ type DeviceTaintRule struct {
|
||||
// Spec specifies the selector and one taint.
|
||||
//
|
||||
// Changing the spec automatically increments the metadata.generation number.
|
||||
// +required
|
||||
Spec DeviceTaintRuleSpec `json:"spec" protobuf:"bytes,2,name=spec"`
|
||||
|
||||
// Status provides information about what was requested in the spec.
|
||||
@@ -332,3 +344,233 @@ type DeviceTaintRuleList struct {
|
||||
// Items is the list of DeviceTaintRules.
|
||||
Items []DeviceTaintRule `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||
}
|
||||
|
||||
// +genclient
|
||||
// +genclient:nonNamespaced
|
||||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
|
||||
// +k8s:prerelease-lifecycle-gen:introduced=1.36
|
||||
// +k8s:supportsSubresource="/status"
|
||||
|
||||
// ResourcePoolStatusRequest triggers a one-time calculation of resource pool status
|
||||
// based on the provided filters. Once status is set, the request is considered complete and will not be reprocessed.
|
||||
// Users should delete and recreate requests to get updated information.
|
||||
type ResourcePoolStatusRequest struct {
|
||||
metav1.TypeMeta `json:",inline"`
|
||||
// Standard object metadata
|
||||
// +required
|
||||
metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||
|
||||
// Spec defines the filters for which pools to include in the status.
|
||||
// The spec is immutable once created.
|
||||
//
|
||||
// +required
|
||||
// +k8s:immutable
|
||||
Spec ResourcePoolStatusRequestSpec `json:"spec" protobuf:"bytes,2,name=spec"`
|
||||
|
||||
// Status is populated by the controller with the calculated pool status.
|
||||
// When status is non-nil, the request is considered complete and the
|
||||
// entire object becomes immutable.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
Status *ResourcePoolStatusRequestStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||
}
|
||||
|
||||
// ResourcePoolStatusRequestSpec defines the filters for the pool status request.
|
||||
type ResourcePoolStatusRequestSpec struct {
|
||||
// Driver specifies the DRA driver name to filter pools.
|
||||
// Only pools from ResourceSlices with this driver will be included.
|
||||
// Must be a DNS subdomain (e.g., "gpu.example.com").
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:format=k8s-long-name-caseless
|
||||
Driver string `json:"driver" protobuf:"bytes,1,name=driver"`
|
||||
|
||||
// PoolName optionally filters to a specific pool name.
|
||||
// If not specified, all pools from the specified driver are included.
|
||||
// When specified, must be a non-empty valid resource pool name
|
||||
// (DNS subdomains separated by "/").
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:format=k8s-resource-pool-name
|
||||
PoolName *string `json:"poolName,omitempty" protobuf:"bytes,2,opt,name=poolName"`
|
||||
|
||||
// Limit optionally specifies the maximum number of pools to return in the status.
|
||||
// If more pools match the filter criteria, the response will be truncated
|
||||
// (i.e., len(status.pools) < status.poolCount).
|
||||
//
|
||||
// Default: 100
|
||||
// Minimum: 1
|
||||
// Maximum: 1000
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +default=100
|
||||
// +k8s:minimum=1
|
||||
// +k8s:maximum=1000
|
||||
Limit *int32 `json:"limit,omitempty" protobuf:"varint,3,opt,name=limit"`
|
||||
}
|
||||
|
||||
// ResourcePoolStatusRequestLimitDefault is the default value for spec.limit.
|
||||
const ResourcePoolStatusRequestLimitDefault int32 = 100
|
||||
|
||||
// ResourcePoolStatusRequestLimitMax is the maximum allowed value for spec.limit.
|
||||
const ResourcePoolStatusRequestLimitMax int32 = 1000
|
||||
|
||||
// ResourcePoolStatusRequestStatus contains the calculated pool status information.
|
||||
type ResourcePoolStatusRequestStatus struct {
|
||||
// PoolCount is the total number of pools that matched the filter criteria,
|
||||
// regardless of truncation. This helps users understand how many pools exist
|
||||
// even when the response is truncated. A value of 0 means no pools matched
|
||||
// the filter criteria.
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:minimum=0
|
||||
PoolCount *int32 `json:"poolCount,omitempty" protobuf:"varint,6,opt,name=poolCount"`
|
||||
|
||||
// Pools contains the first `spec.limit` matching pools, sorted by driver
|
||||
// then pool name. If `len(pools) < poolCount`, the list was truncated.
|
||||
// When omitted, no pools matched the request filters.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +listType=atomic
|
||||
// +k8s:listType=atomic
|
||||
// +k8s:maxItems=1000
|
||||
Pools []PoolStatus `json:"pools,omitempty" protobuf:"bytes,2,rep,name=pools"`
|
||||
|
||||
// Conditions provide information about the state of the request.
|
||||
// A condition with type=Complete or type=Failed will always be set
|
||||
// when the status is populated.
|
||||
//
|
||||
// Known condition types:
|
||||
// - "Complete": True when the request has been processed successfully
|
||||
// - "Failed": True when the request could not be processed
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +listType=map
|
||||
// +k8s:listType=map
|
||||
// +listMapKey=type
|
||||
// +k8s:listMapKey=type
|
||||
// +patchStrategy=merge
|
||||
// +patchMergeKey=type
|
||||
// +k8s:maxItems=10
|
||||
Conditions []metav1.Condition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,3,rep,name=conditions"`
|
||||
}
|
||||
|
||||
// PoolStatus contains status information for a single resource pool.
|
||||
type PoolStatus struct {
|
||||
// Driver is the DRA driver name for this pool.
|
||||
// Must be a DNS subdomain (e.g., "gpu.example.com").
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:format=k8s-long-name-caseless
|
||||
Driver string `json:"driver,omitempty" protobuf:"bytes,1,name=driver"`
|
||||
|
||||
// PoolName is the name of the pool.
|
||||
// Must be a valid resource pool name (DNS subdomains separated by "/").
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:format=k8s-resource-pool-name
|
||||
PoolName string `json:"poolName,omitempty" protobuf:"bytes,2,name=poolName"`
|
||||
|
||||
// Generation is the pool generation observed across all ResourceSlices
|
||||
// in this pool. Only the latest generation is reported. During a generation
|
||||
// rollout, if not all slices at the latest generation have been published,
|
||||
// the pool is included with a validationError and device counts unset.
|
||||
//
|
||||
// +required
|
||||
// +k8s:required
|
||||
// +k8s:minimum=0
|
||||
Generation int64 `json:"generation" protobuf:"varint,9,opt,name=generation"`
|
||||
|
||||
// ResourceSliceCount is the number of ResourceSlices that make up this pool.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=1
|
||||
ResourceSliceCount *int32 `json:"resourceSliceCount,omitempty" protobuf:"varint,8,opt,name=resourceSliceCount"`
|
||||
|
||||
// TotalDevices is the total number of devices in the pool across all slices.
|
||||
// A value of 0 means the pool has no devices.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=0
|
||||
TotalDevices *int32 `json:"totalDevices,omitempty" protobuf:"varint,4,opt,name=totalDevices"`
|
||||
|
||||
// AllocatedDevices is the number of devices currently allocated to claims.
|
||||
// A value of 0 means no devices are allocated.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=0
|
||||
AllocatedDevices *int32 `json:"allocatedDevices,omitempty" protobuf:"varint,5,opt,name=allocatedDevices"`
|
||||
|
||||
// AvailableDevices is the number of devices available for allocation.
|
||||
// This equals TotalDevices - AllocatedDevices - UnavailableDevices.
|
||||
// A value of 0 means no devices are currently available.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=0
|
||||
AvailableDevices *int32 `json:"availableDevices,omitempty" protobuf:"varint,6,opt,name=availableDevices"`
|
||||
|
||||
// UnavailableDevices is the number of devices that are not available
|
||||
// due to taints or other conditions, but are not allocated.
|
||||
// A value of 0 means all unallocated devices are available.
|
||||
// May be unset when validationError is set.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:minimum=0
|
||||
UnavailableDevices *int32 `json:"unavailableDevices,omitempty" protobuf:"varint,7,opt,name=unavailableDevices"`
|
||||
|
||||
// NodeName is the node this pool is associated with.
|
||||
// When omitted, the pool is not associated with a specific node.
|
||||
// Must be a valid DNS subdomain name (RFC1123).
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:format=k8s-long-name
|
||||
NodeName *string `json:"nodeName,omitempty" protobuf:"bytes,3,opt,name=nodeName"`
|
||||
|
||||
// ValidationError is set when the pool's data could not be fully
|
||||
// validated (e.g., incomplete slice publication). When set, device
|
||||
// count fields and ResourceSliceCount may be unset.
|
||||
//
|
||||
// +optional
|
||||
// +k8s:optional
|
||||
// +k8s:maxBytes=256
|
||||
ValidationError *string `json:"validationError,omitempty" protobuf:"bytes,10,opt,name=validationError"`
|
||||
}
|
||||
|
||||
// ResourcePoolStatusRequestConditionComplete is the condition type for completed requests.
|
||||
const ResourcePoolStatusRequestConditionComplete = "Complete"
|
||||
|
||||
// ResourcePoolStatusRequestConditionFailed is the condition type for failed requests.
|
||||
const ResourcePoolStatusRequestConditionFailed = "Failed"
|
||||
|
||||
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
|
||||
// +k8s:prerelease-lifecycle-gen:introduced=1.36
|
||||
|
||||
// ResourcePoolStatusRequestList is a collection of ResourcePoolStatusRequests.
|
||||
type ResourcePoolStatusRequestList struct {
|
||||
metav1.TypeMeta `json:",inline"`
|
||||
// Standard list metadata
|
||||
// +optional
|
||||
metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"`
|
||||
|
||||
// Items is the list of ResourcePoolStatusRequests.
|
||||
Items []ResourcePoolStatusRequest `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||
}
|
||||
|
||||
+62
-1
@@ -50,7 +50,7 @@ var map_DeviceTaint = map[string]string{
|
||||
"key": "The taint key to be applied to a device. Must be a label name.",
|
||||
"value": "The taint value corresponding to the taint key. Must be a label value.",
|
||||
"effect": "The effect of the taint on claims that do not tolerate the taint and through such claims on the pods using them.\n\nValid effects are None, NoSchedule and NoExecute. PreferNoSchedule as used for nodes is not valid here. More effects may get added in the future. Consumers must treat unknown effects like None.",
|
||||
"timeAdded": "TimeAdded represents the time at which the taint was added. Added automatically during create or update if not set.",
|
||||
"timeAdded": "TimeAdded represents the time at which the taint was added or (only in a DeviceTaintRule) the effect was modified. Added automatically during create or update if not set.\n\nIn addition, in a DeviceTaintRule a value provided during an update gets replaced with the current time if the provided value is the same as the old one and the new effect is different. Changing the key and/or value while keeping the effect unchanged is possible and does not update the time stamp because the eviction which uses it is either already started (NoExecute) or not started yet (NoEffect, NoSchedule).",
|
||||
}
|
||||
|
||||
func (DeviceTaint) SwaggerDoc() map[string]string {
|
||||
@@ -108,4 +108,65 @@ func (DeviceTaintSelector) SwaggerDoc() map[string]string {
|
||||
return map_DeviceTaintSelector
|
||||
}
|
||||
|
||||
var map_PoolStatus = map[string]string{
|
||||
"": "PoolStatus contains status information for a single resource pool.",
|
||||
"driver": "Driver is the DRA driver name for this pool. Must be a DNS subdomain (e.g., \"gpu.example.com\").",
|
||||
"poolName": "PoolName is the name of the pool. Must be a valid resource pool name (DNS subdomains separated by \"/\").",
|
||||
"generation": "Generation is the pool generation observed across all ResourceSlices in this pool. Only the latest generation is reported. During a generation rollout, if not all slices at the latest generation have been published, the pool is included with a validationError and device counts unset.",
|
||||
"resourceSliceCount": "ResourceSliceCount is the number of ResourceSlices that make up this pool. May be unset when validationError is set.",
|
||||
"totalDevices": "TotalDevices is the total number of devices in the pool across all slices. A value of 0 means the pool has no devices. May be unset when validationError is set.",
|
||||
"allocatedDevices": "AllocatedDevices is the number of devices currently allocated to claims. A value of 0 means no devices are allocated. May be unset when validationError is set.",
|
||||
"availableDevices": "AvailableDevices is the number of devices available for allocation. This equals TotalDevices - AllocatedDevices - UnavailableDevices. A value of 0 means no devices are currently available. May be unset when validationError is set.",
|
||||
"unavailableDevices": "UnavailableDevices is the number of devices that are not available due to taints or other conditions, but are not allocated. A value of 0 means all unallocated devices are available. May be unset when validationError is set.",
|
||||
"nodeName": "NodeName is the node this pool is associated with. When omitted, the pool is not associated with a specific node. Must be a valid DNS subdomain name (RFC1123).",
|
||||
"validationError": "ValidationError is set when the pool's data could not be fully validated (e.g., incomplete slice publication). When set, device count fields and ResourceSliceCount may be unset.",
|
||||
}
|
||||
|
||||
func (PoolStatus) SwaggerDoc() map[string]string {
|
||||
return map_PoolStatus
|
||||
}
|
||||
|
||||
var map_ResourcePoolStatusRequest = map[string]string{
|
||||
"": "ResourcePoolStatusRequest triggers a one-time calculation of resource pool status based on the provided filters. Once status is set, the request is considered complete and will not be reprocessed. Users should delete and recreate requests to get updated information.",
|
||||
"metadata": "Standard object metadata",
|
||||
"spec": "Spec defines the filters for which pools to include in the status. The spec is immutable once created.",
|
||||
"status": "Status is populated by the controller with the calculated pool status. When status is non-nil, the request is considered complete and the entire object becomes immutable.",
|
||||
}
|
||||
|
||||
func (ResourcePoolStatusRequest) SwaggerDoc() map[string]string {
|
||||
return map_ResourcePoolStatusRequest
|
||||
}
|
||||
|
||||
var map_ResourcePoolStatusRequestList = map[string]string{
|
||||
"": "ResourcePoolStatusRequestList is a collection of ResourcePoolStatusRequests.",
|
||||
"metadata": "Standard list metadata",
|
||||
"items": "Items is the list of ResourcePoolStatusRequests.",
|
||||
}
|
||||
|
||||
func (ResourcePoolStatusRequestList) SwaggerDoc() map[string]string {
|
||||
return map_ResourcePoolStatusRequestList
|
||||
}
|
||||
|
||||
var map_ResourcePoolStatusRequestSpec = map[string]string{
|
||||
"": "ResourcePoolStatusRequestSpec defines the filters for the pool status request.",
|
||||
"driver": "Driver specifies the DRA driver name to filter pools. Only pools from ResourceSlices with this driver will be included. Must be a DNS subdomain (e.g., \"gpu.example.com\").",
|
||||
"poolName": "PoolName optionally filters to a specific pool name. If not specified, all pools from the specified driver are included. When specified, must be a non-empty valid resource pool name (DNS subdomains separated by \"/\").",
|
||||
"limit": "Limit optionally specifies the maximum number of pools to return in the status. If more pools match the filter criteria, the response will be truncated (i.e., len(status.pools) < status.poolCount).\n\nDefault: 100 Minimum: 1 Maximum: 1000",
|
||||
}
|
||||
|
||||
func (ResourcePoolStatusRequestSpec) SwaggerDoc() map[string]string {
|
||||
return map_ResourcePoolStatusRequestSpec
|
||||
}
|
||||
|
||||
var map_ResourcePoolStatusRequestStatus = map[string]string{
|
||||
"": "ResourcePoolStatusRequestStatus contains the calculated pool status information.",
|
||||
"poolCount": "PoolCount is the total number of pools that matched the filter criteria, regardless of truncation. This helps users understand how many pools exist even when the response is truncated. A value of 0 means no pools matched the filter criteria.",
|
||||
"pools": "Pools contains the first `spec.limit` matching pools, sorted by driver then pool name. If `len(pools) < poolCount`, the list was truncated. When omitted, no pools matched the request filters.",
|
||||
"conditions": "Conditions provide information about the state of the request. A condition with type=Complete or type=Failed will always be set when the status is populated.\n\nKnown condition types: - \"Complete\": True when the request has been processed successfully - \"Failed\": True when the request could not be processed",
|
||||
}
|
||||
|
||||
func (ResourcePoolStatusRequestStatus) SwaggerDoc() map[string]string {
|
||||
return map_ResourcePoolStatusRequestStatus
|
||||
}
|
||||
|
||||
// AUTO-GENERATED FUNCTIONS END HERE
|
||||
|
||||
+177
@@ -219,3 +219,180 @@ func (in *DeviceTaintSelector) DeepCopy() *DeviceTaintSelector {
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *PoolStatus) DeepCopyInto(out *PoolStatus) {
|
||||
*out = *in
|
||||
if in.ResourceSliceCount != nil {
|
||||
in, out := &in.ResourceSliceCount, &out.ResourceSliceCount
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
if in.TotalDevices != nil {
|
||||
in, out := &in.TotalDevices, &out.TotalDevices
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
if in.AllocatedDevices != nil {
|
||||
in, out := &in.AllocatedDevices, &out.AllocatedDevices
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
if in.AvailableDevices != nil {
|
||||
in, out := &in.AvailableDevices, &out.AvailableDevices
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
if in.UnavailableDevices != nil {
|
||||
in, out := &in.UnavailableDevices, &out.UnavailableDevices
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
if in.NodeName != nil {
|
||||
in, out := &in.NodeName, &out.NodeName
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
if in.ValidationError != nil {
|
||||
in, out := &in.ValidationError, &out.ValidationError
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PoolStatus.
|
||||
func (in *PoolStatus) DeepCopy() *PoolStatus {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(PoolStatus)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *ResourcePoolStatusRequest) DeepCopyInto(out *ResourcePoolStatusRequest) {
|
||||
*out = *in
|
||||
out.TypeMeta = in.TypeMeta
|
||||
in.ObjectMeta.DeepCopyInto(&out.ObjectMeta)
|
||||
in.Spec.DeepCopyInto(&out.Spec)
|
||||
if in.Status != nil {
|
||||
in, out := &in.Status, &out.Status
|
||||
*out = new(ResourcePoolStatusRequestStatus)
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourcePoolStatusRequest.
|
||||
func (in *ResourcePoolStatusRequest) DeepCopy() *ResourcePoolStatusRequest {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(ResourcePoolStatusRequest)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
|
||||
func (in *ResourcePoolStatusRequest) DeepCopyObject() runtime.Object {
|
||||
if c := in.DeepCopy(); c != nil {
|
||||
return c
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *ResourcePoolStatusRequestList) DeepCopyInto(out *ResourcePoolStatusRequestList) {
|
||||
*out = *in
|
||||
out.TypeMeta = in.TypeMeta
|
||||
in.ListMeta.DeepCopyInto(&out.ListMeta)
|
||||
if in.Items != nil {
|
||||
in, out := &in.Items, &out.Items
|
||||
*out = make([]ResourcePoolStatusRequest, len(*in))
|
||||
for i := range *in {
|
||||
(*in)[i].DeepCopyInto(&(*out)[i])
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourcePoolStatusRequestList.
|
||||
func (in *ResourcePoolStatusRequestList) DeepCopy() *ResourcePoolStatusRequestList {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(ResourcePoolStatusRequestList)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
|
||||
func (in *ResourcePoolStatusRequestList) DeepCopyObject() runtime.Object {
|
||||
if c := in.DeepCopy(); c != nil {
|
||||
return c
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *ResourcePoolStatusRequestSpec) DeepCopyInto(out *ResourcePoolStatusRequestSpec) {
|
||||
*out = *in
|
||||
if in.PoolName != nil {
|
||||
in, out := &in.PoolName, &out.PoolName
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
||||
if in.Limit != nil {
|
||||
in, out := &in.Limit, &out.Limit
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourcePoolStatusRequestSpec.
|
||||
func (in *ResourcePoolStatusRequestSpec) DeepCopy() *ResourcePoolStatusRequestSpec {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(ResourcePoolStatusRequestSpec)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *ResourcePoolStatusRequestStatus) DeepCopyInto(out *ResourcePoolStatusRequestStatus) {
|
||||
*out = *in
|
||||
if in.PoolCount != nil {
|
||||
in, out := &in.PoolCount, &out.PoolCount
|
||||
*out = new(int32)
|
||||
**out = **in
|
||||
}
|
||||
if in.Pools != nil {
|
||||
in, out := &in.Pools, &out.Pools
|
||||
*out = make([]PoolStatus, len(*in))
|
||||
for i := range *in {
|
||||
(*in)[i].DeepCopyInto(&(*out)[i])
|
||||
}
|
||||
}
|
||||
if in.Conditions != nil {
|
||||
in, out := &in.Conditions, &out.Conditions
|
||||
*out = make([]v1.Condition, len(*in))
|
||||
for i := range *in {
|
||||
(*in)[i].DeepCopyInto(&(*out)[i])
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourcePoolStatusRequestStatus.
|
||||
func (in *ResourcePoolStatusRequestStatus) DeepCopy() *ResourcePoolStatusRequestStatus {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(ResourcePoolStatusRequestStatus)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
+25
@@ -60,3 +60,28 @@ func (in DeviceTaintRuleStatus) OpenAPIModelName() string {
|
||||
func (in DeviceTaintSelector) OpenAPIModelName() string {
|
||||
return "io.k8s.api.resource.v1alpha3.DeviceTaintSelector"
|
||||
}
|
||||
|
||||
// OpenAPIModelName returns the OpenAPI model name for this type.
|
||||
func (in PoolStatus) OpenAPIModelName() string {
|
||||
return "io.k8s.api.resource.v1alpha3.PoolStatus"
|
||||
}
|
||||
|
||||
// OpenAPIModelName returns the OpenAPI model name for this type.
|
||||
func (in ResourcePoolStatusRequest) OpenAPIModelName() string {
|
||||
return "io.k8s.api.resource.v1alpha3.ResourcePoolStatusRequest"
|
||||
}
|
||||
|
||||
// OpenAPIModelName returns the OpenAPI model name for this type.
|
||||
func (in ResourcePoolStatusRequestList) OpenAPIModelName() string {
|
||||
return "io.k8s.api.resource.v1alpha3.ResourcePoolStatusRequestList"
|
||||
}
|
||||
|
||||
// OpenAPIModelName returns the OpenAPI model name for this type.
|
||||
func (in ResourcePoolStatusRequestSpec) OpenAPIModelName() string {
|
||||
return "io.k8s.api.resource.v1alpha3.ResourcePoolStatusRequestSpec"
|
||||
}
|
||||
|
||||
// OpenAPIModelName returns the OpenAPI model name for this type.
|
||||
func (in ResourcePoolStatusRequestStatus) OpenAPIModelName() string {
|
||||
return "io.k8s.api.resource.v1alpha3.ResourcePoolStatusRequestStatus"
|
||||
}
|
||||
|
||||
+36
@@ -56,3 +56,39 @@ func (in *DeviceTaintRuleList) APILifecycleDeprecated() (major, minor int) {
|
||||
func (in *DeviceTaintRuleList) APILifecycleRemoved() (major, minor int) {
|
||||
return 1, 39
|
||||
}
|
||||
|
||||
// APILifecycleIntroduced is an autogenerated function, returning the release in which the API struct was introduced as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:introduced" tags in types.go.
|
||||
func (in *ResourcePoolStatusRequest) APILifecycleIntroduced() (major, minor int) {
|
||||
return 1, 36
|
||||
}
|
||||
|
||||
// APILifecycleDeprecated is an autogenerated function, returning the release in which the API struct was or will be deprecated as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:deprecated" tags in types.go or "k8s:prerelease-lifecycle-gen:introduced" plus three minor.
|
||||
func (in *ResourcePoolStatusRequest) APILifecycleDeprecated() (major, minor int) {
|
||||
return 1, 39
|
||||
}
|
||||
|
||||
// APILifecycleRemoved is an autogenerated function, returning the release in which the API is no longer served as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:removed" tags in types.go or "k8s:prerelease-lifecycle-gen:deprecated" plus three minor.
|
||||
func (in *ResourcePoolStatusRequest) APILifecycleRemoved() (major, minor int) {
|
||||
return 1, 42
|
||||
}
|
||||
|
||||
// APILifecycleIntroduced is an autogenerated function, returning the release in which the API struct was introduced as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:introduced" tags in types.go.
|
||||
func (in *ResourcePoolStatusRequestList) APILifecycleIntroduced() (major, minor int) {
|
||||
return 1, 36
|
||||
}
|
||||
|
||||
// APILifecycleDeprecated is an autogenerated function, returning the release in which the API struct was or will be deprecated as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:deprecated" tags in types.go or "k8s:prerelease-lifecycle-gen:introduced" plus three minor.
|
||||
func (in *ResourcePoolStatusRequestList) APILifecycleDeprecated() (major, minor int) {
|
||||
return 1, 39
|
||||
}
|
||||
|
||||
// APILifecycleRemoved is an autogenerated function, returning the release in which the API is no longer served as int versions of major and minor for comparison.
|
||||
// It is controlled by "k8s:prerelease-lifecycle-gen:removed" tags in types.go or "k8s:prerelease-lifecycle-gen:deprecated" plus three minor.
|
||||
func (in *ResourcePoolStatusRequestList) APILifecycleRemoved() (major, minor int) {
|
||||
return 1, 42
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user