Merge pull request #134152 from pohly/dra-device-taints-1.35

DRA: device taints: new ResourceSlice API, new features

Kubernetes-commit: c1a6a3ca71a88a3d43580b2ffce6966c58f8bd56
This commit is contained in:
Kubernetes Publisher
2025-11-04 15:32:07 -08:00
21 changed files with 139 additions and 206 deletions

View File

@@ -13486,19 +13486,6 @@ var schemaYAML = typed.YAMLObject(`types:
elementType:
namedType: io.k8s.api.resource.v1.CounterSet
elementRelationship: atomic
- name: io.k8s.api.resource.v1alpha3.CELDeviceSelector
map:
fields:
- name: expression
type:
scalar: string
default: ""
- name: io.k8s.api.resource.v1alpha3.DeviceSelector
map:
fields:
- name: cel
type:
namedType: io.k8s.api.resource.v1alpha3.CELDeviceSelector
- name: io.k8s.api.resource.v1alpha3.DeviceTaint
map:
fields:
@@ -13533,6 +13520,10 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: io.k8s.api.resource.v1alpha3.DeviceTaintRuleSpec
default: {}
- name: status
type:
namedType: io.k8s.api.resource.v1alpha3.DeviceTaintRuleStatus
default: {}
- name: io.k8s.api.resource.v1alpha3.DeviceTaintRuleSpec
map:
fields:
@@ -13543,27 +13534,29 @@ var schemaYAML = typed.YAMLObject(`types:
type:
namedType: io.k8s.api.resource.v1alpha3.DeviceTaint
default: {}
- name: io.k8s.api.resource.v1alpha3.DeviceTaintRuleStatus
map:
fields:
- name: conditions
type:
list:
elementType:
namedType: io.k8s.apimachinery.pkg.apis.meta.v1.Condition
elementRelationship: associative
keys:
- type
- name: io.k8s.api.resource.v1alpha3.DeviceTaintSelector
map:
fields:
- name: device
type:
scalar: string
- name: deviceClassName
type:
scalar: string
- name: driver
type:
scalar: string
- name: pool
type:
scalar: string
- name: selectors
type:
list:
elementType:
namedType: io.k8s.api.resource.v1alpha3.DeviceSelector
elementRelationship: atomic
- name: io.k8s.api.resource.v1beta1.AllocatedDeviceStatus
map:
fields:

View File

@@ -72,7 +72,9 @@ type DeviceApplyConfiguration struct {
AllNodes *bool `json:"allNodes,omitempty"`
// If specified, these are the driver-defined taints.
//
// The maximum number of taints is 4.
// The maximum number of taints is 16. If taints are set for
// any device in a ResourceSlice, then the maximum number of
// allowed devices per ResourceSlice is 64 instead of 128.
//
// This is an alpha field and requires enabling the DRADeviceTaints
// feature gate.

View File

@@ -38,8 +38,10 @@ type DeviceTaintApplyConfiguration struct {
Value *string `json:"value,omitempty"`
// The effect of the taint on claims that do not tolerate the taint
// and through such claims on the pods using them.
// Valid effects are NoSchedule and NoExecute. PreferNoSchedule as used for
// nodes is not valid here.
//
// Valid 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.
Effect *resourcev1.DeviceTaintEffect `json:"effect,omitempty"`
// TimeAdded represents the time at which the taint was added.
// Added automatically during create or update if not set.

View File

@@ -62,7 +62,7 @@ type ResourceSliceSpecApplyConfiguration struct {
AllNodes *bool `json:"allNodes,omitempty"`
// Devices lists some or all of the devices in this pool.
//
// Must not have more than 128 entries.
// Must not have more than 128 entries. If any device uses taints the limit is 64.
Devices []DeviceApplyConfiguration `json:"devices,omitempty"`
// PerDeviceNodeSelection defines whether the access from nodes to
// resources in the pool is set on the ResourceSlice level or on each

View File

@@ -1,91 +0,0 @@
/*
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 applyconfiguration-gen. DO NOT EDIT.
package v1alpha3
// CELDeviceSelectorApplyConfiguration represents a declarative configuration of the CELDeviceSelector type for use
// with apply.
//
// CELDeviceSelector contains a CEL expression for selecting a device.
type CELDeviceSelectorApplyConfiguration struct {
// Expression is a CEL expression which evaluates a single device. It
// must evaluate to true when the device under consideration satisfies
// the desired criteria, and false when it does not. Any other result
// is an error and causes allocation of devices to abort.
//
// The expression's input is an object named "device", which carries
// the following properties:
// - driver (string): the name of the driver which defines this device.
// - attributes (map[string]object): the device's attributes, grouped by prefix
// (e.g. device.attributes["dra.example.com"] evaluates to an object with all
// of the attributes which were prefixed by "dra.example.com".
// - capacity (map[string]object): the device's capacities, grouped by prefix.
//
// Example: Consider a device with driver="dra.example.com", which exposes
// two attributes named "model" and "ext.example.com/family" and which
// exposes one capacity named "modules". This input to this expression
// would have the following fields:
//
// device.driver
// device.attributes["dra.example.com"].model
// device.attributes["ext.example.com"].family
// device.capacity["dra.example.com"].modules
//
// The device.driver field can be used to check for a specific driver,
// either as a high-level precondition (i.e. you only want to consider
// devices from this driver) or as part of a multi-clause expression
// that is meant to consider devices from different drivers.
//
// The value type of each attribute is defined by the device
// definition, and users who write these expressions must consult the
// documentation for their specific drivers. The value type of each
// capacity is Quantity.
//
// If an unknown prefix is used as a lookup in either device.attributes
// or device.capacity, an empty map will be returned. Any reference to
// an unknown field will cause an evaluation error and allocation to
// abort.
//
// A robust expression should check for the existence of attributes
// before referencing them.
//
// For ease of use, the cel.bind() function is enabled, and can be used
// to simplify expressions that access multiple attributes with the
// same domain. For example:
//
// cel.bind(dra, device.attributes["dra.example.com"], dra.someBool && dra.anotherBool)
//
// The length of the expression must be smaller or equal to 10 Ki. The
// cost of evaluating it is also limited based on the estimated number
// of logical steps.
Expression *string `json:"expression,omitempty"`
}
// CELDeviceSelectorApplyConfiguration constructs a declarative configuration of the CELDeviceSelector type for use with
// apply.
func CELDeviceSelector() *CELDeviceSelectorApplyConfiguration {
return &CELDeviceSelectorApplyConfiguration{}
}
// WithExpression sets the Expression field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Expression field is set to the value of the last call.
func (b *CELDeviceSelectorApplyConfiguration) WithExpression(value string) *CELDeviceSelectorApplyConfiguration {
b.Expression = &value
return b
}

View File

@@ -1,42 +0,0 @@
/*
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 applyconfiguration-gen. DO NOT EDIT.
package v1alpha3
// DeviceSelectorApplyConfiguration represents a declarative configuration of the DeviceSelector type for use
// with apply.
//
// DeviceSelector must have exactly one field set.
type DeviceSelectorApplyConfiguration struct {
// CEL contains a CEL expression for selecting a device.
CEL *CELDeviceSelectorApplyConfiguration `json:"cel,omitempty"`
}
// DeviceSelectorApplyConfiguration constructs a declarative configuration of the DeviceSelector type for use with
// apply.
func DeviceSelector() *DeviceSelectorApplyConfiguration {
return &DeviceSelectorApplyConfiguration{}
}
// WithCEL sets the CEL field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the CEL field is set to the value of the last call.
func (b *DeviceSelectorApplyConfiguration) WithCEL(value *CELDeviceSelectorApplyConfiguration) *DeviceSelectorApplyConfiguration {
b.CEL = value
return b
}

View File

@@ -38,8 +38,10 @@ type DeviceTaintApplyConfiguration struct {
Value *string `json:"value,omitempty"`
// The effect of the taint on claims that do not tolerate the taint
// and through such claims on the pods using them.
// Valid effects are NoSchedule and NoExecute. PreferNoSchedule as used for
// nodes is not valid here.
//
// Valid 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.
Effect *resourcev1alpha3.DeviceTaintEffect `json:"effect,omitempty"`
// TimeAdded represents the time at which the taint was added.
// Added automatically during create or update if not set.

View File

@@ -41,6 +41,8 @@ type DeviceTaintRuleApplyConfiguration struct {
//
// Changing the spec automatically increments the metadata.generation number.
Spec *DeviceTaintRuleSpecApplyConfiguration `json:"spec,omitempty"`
// Status provides information about what was requested in the spec.
Status *DeviceTaintRuleStatusApplyConfiguration `json:"status,omitempty"`
}
// DeviceTaintRule constructs a declarative configuration of the DeviceTaintRule type for use with
@@ -87,6 +89,12 @@ func ExtractDeviceTaintRule(deviceTaintRule *resourcev1alpha3.DeviceTaintRule, f
return ExtractDeviceTaintRuleFrom(deviceTaintRule, fieldManager, "")
}
// ExtractDeviceTaintRuleStatus extracts the applied configuration owned by fieldManager from
// deviceTaintRule for the status subresource.
func ExtractDeviceTaintRuleStatus(deviceTaintRule *resourcev1alpha3.DeviceTaintRule, fieldManager string) (*DeviceTaintRuleApplyConfiguration, error) {
return ExtractDeviceTaintRuleFrom(deviceTaintRule, fieldManager, "status")
}
func (b DeviceTaintRuleApplyConfiguration) IsApplyConfiguration() {}
// WithKind sets the Kind field in the declarative configuration to the given value
@@ -255,6 +263,14 @@ func (b *DeviceTaintRuleApplyConfiguration) WithSpec(value *DeviceTaintRuleSpecA
return b
}
// WithStatus sets the Status field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Status field is set to the value of the last call.
func (b *DeviceTaintRuleApplyConfiguration) WithStatus(value *DeviceTaintRuleStatusApplyConfiguration) *DeviceTaintRuleApplyConfiguration {
b.Status = value
return b
}
// GetKind retrieves the value of the Kind field in the declarative configuration.
func (b *DeviceTaintRuleApplyConfiguration) GetKind() *string {
return b.TypeMetaApplyConfiguration.Kind

View File

@@ -24,7 +24,7 @@ package v1alpha3
// DeviceTaintRuleSpec specifies the selector and one taint.
type DeviceTaintRuleSpecApplyConfiguration struct {
// DeviceSelector defines which device(s) the taint is applied to.
// All selector criteria must be satified for a device to
// All selector criteria must be satisfied for a device to
// match. The empty selector matches all devices. Without
// a selector, no devices are matches.
DeviceSelector *DeviceTaintSelectorApplyConfiguration `json:"deviceSelector,omitempty"`

View File

@@ -0,0 +1,70 @@
/*
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 applyconfiguration-gen. DO NOT EDIT.
package v1alpha3
import (
v1 "k8s.io/client-go/applyconfigurations/meta/v1"
)
// DeviceTaintRuleStatusApplyConfiguration represents a declarative configuration of the DeviceTaintRuleStatus type for use
// with apply.
//
// DeviceTaintRuleStatus provides information about an on-going pod eviction.
type DeviceTaintRuleStatusApplyConfiguration struct {
// Conditions provide information about the state of the DeviceTaintRule
// and the cluster at some point in time,
// in a machine-readable and human-readable format.
//
// The following condition is currently defined as part of this API, more may
// get added:
// - Type: EvictionInProgress
// - Status: True if there are currently pods which need to be evicted, False otherwise
// (includes the effects which don't cause eviction).
// - Reason: not specified, may change
// - Message: includes information about number of pending pods and already evicted pods
// in a human-readable format, updated periodically, may change
//
// For `effect: None`, the condition above gets set once for each change to
// the spec, with the message containing information about what would happen
// if the effect was `NoExecute`. This feedback can be used to decide whether
// changing the effect to `NoExecute` will work as intended. It only gets
// set once to avoid having to constantly update the status.
//
// Must have 8 or fewer entries.
Conditions []v1.ConditionApplyConfiguration `json:"conditions,omitempty"`
}
// DeviceTaintRuleStatusApplyConfiguration constructs a declarative configuration of the DeviceTaintRuleStatus type for use with
// apply.
func DeviceTaintRuleStatus() *DeviceTaintRuleStatusApplyConfiguration {
return &DeviceTaintRuleStatusApplyConfiguration{}
}
// WithConditions adds the given value to the Conditions field in the declarative configuration
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
// If called multiple times, values provided by each call will be appended to the Conditions field.
func (b *DeviceTaintRuleStatusApplyConfiguration) WithConditions(values ...*v1.ConditionApplyConfiguration) *DeviceTaintRuleStatusApplyConfiguration {
for i := range values {
if values[i] == nil {
panic("nil value passed to WithConditions")
}
b.Conditions = append(b.Conditions, *values[i])
}
return b
}

View File

@@ -25,10 +25,6 @@ package v1alpha3
// The empty selector matches all devices. Without a selector, no devices
// are matched.
type DeviceTaintSelectorApplyConfiguration struct {
// If DeviceClassName is set, the selectors defined there must be
// satisfied by a device to be selected. This field corresponds
// to class.metadata.name.
DeviceClassName *string `json:"deviceClassName,omitempty"`
// If driver is set, only devices from that driver are selected.
// This fields corresponds to slice.spec.driver.
Driver *string `json:"driver,omitempty"`
@@ -47,10 +43,6 @@ type DeviceTaintSelectorApplyConfiguration struct {
// Setting also driver and pool may be required to avoid ambiguity,
// but is not required.
Device *string `json:"device,omitempty"`
// Selectors contains the same selection criteria as a ResourceClaim.
// Currently, CEL expressions are supported. All of these selectors
// must be satisfied.
Selectors []DeviceSelectorApplyConfiguration `json:"selectors,omitempty"`
}
// DeviceTaintSelectorApplyConfiguration constructs a declarative configuration of the DeviceTaintSelector type for use with
@@ -59,14 +51,6 @@ func DeviceTaintSelector() *DeviceTaintSelectorApplyConfiguration {
return &DeviceTaintSelectorApplyConfiguration{}
}
// WithDeviceClassName sets the DeviceClassName field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the DeviceClassName field is set to the value of the last call.
func (b *DeviceTaintSelectorApplyConfiguration) WithDeviceClassName(value string) *DeviceTaintSelectorApplyConfiguration {
b.DeviceClassName = &value
return b
}
// WithDriver sets the Driver field in the declarative configuration to the given value
// and returns the receiver, so that objects can be built by chaining "With" function invocations.
// If called multiple times, the Driver field is set to the value of the last call.
@@ -90,16 +74,3 @@ func (b *DeviceTaintSelectorApplyConfiguration) WithDevice(value string) *Device
b.Device = &value
return b
}
// WithSelectors adds the given value to the Selectors field in the declarative configuration
// and returns the receiver, so that objects can be build by chaining "With" function invocations.
// If called multiple times, values provided by each call will be appended to the Selectors field.
func (b *DeviceTaintSelectorApplyConfiguration) WithSelectors(values ...*DeviceSelectorApplyConfiguration) *DeviceTaintSelectorApplyConfiguration {
for i := range values {
if values[i] == nil {
panic("nil value passed to WithSelectors")
}
b.Selectors = append(b.Selectors, *values[i])
}
return b
}

View File

@@ -68,7 +68,9 @@ type BasicDeviceApplyConfiguration struct {
AllNodes *bool `json:"allNodes,omitempty"`
// If specified, these are the driver-defined taints.
//
// The maximum number of taints is 4.
// The maximum number of taints is 16. If taints are set for
// any device in a ResourceSlice, then the maximum number of
// allowed devices per ResourceSlice is 64 instead of 128.
//
// This is an alpha field and requires enabling the DRADeviceTaints
// feature gate.

View File

@@ -38,8 +38,10 @@ type DeviceTaintApplyConfiguration struct {
Value *string `json:"value,omitempty"`
// The effect of the taint on claims that do not tolerate the taint
// and through such claims on the pods using them.
// Valid effects are NoSchedule and NoExecute. PreferNoSchedule as used for
// nodes is not valid here.
//
// Valid 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.
Effect *resourcev1beta1.DeviceTaintEffect `json:"effect,omitempty"`
// TimeAdded represents the time at which the taint was added.
// Added automatically during create or update if not set.

View File

@@ -62,7 +62,7 @@ type ResourceSliceSpecApplyConfiguration struct {
AllNodes *bool `json:"allNodes,omitempty"`
// Devices lists some or all of the devices in this pool.
//
// Must not have more than 128 entries.
// Must not have more than 128 entries. If any device uses taints the limit is 64.
Devices []DeviceApplyConfiguration `json:"devices,omitempty"`
// PerDeviceNodeSelection defines whether the access from nodes to
// resources in the pool is set on the ResourceSlice level or on each

View File

@@ -72,7 +72,9 @@ type DeviceApplyConfiguration struct {
AllNodes *bool `json:"allNodes,omitempty"`
// If specified, these are the driver-defined taints.
//
// The maximum number of taints is 4.
// The maximum number of taints is 16. If taints are set for
// any device in a ResourceSlice, then the maximum number of
// allowed devices per ResourceSlice is 64 instead of 128.
//
// This is an alpha field and requires enabling the DRADeviceTaints
// feature gate.

View File

@@ -38,8 +38,10 @@ type DeviceTaintApplyConfiguration struct {
Value *string `json:"value,omitempty"`
// The effect of the taint on claims that do not tolerate the taint
// and through such claims on the pods using them.
// Valid effects are NoSchedule and NoExecute. PreferNoSchedule as used for
// nodes is not valid here.
//
// Valid 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.
Effect *resourcev1beta2.DeviceTaintEffect `json:"effect,omitempty"`
// TimeAdded represents the time at which the taint was added.
// Added automatically during create or update if not set.

View File

@@ -62,7 +62,7 @@ type ResourceSliceSpecApplyConfiguration struct {
AllNodes *bool `json:"allNodes,omitempty"`
// Devices lists some or all of the devices in this pool.
//
// Must not have more than 128 entries.
// Must not have more than 128 entries. If any device uses taints the limit is 64.
Devices []DeviceApplyConfiguration `json:"devices,omitempty"`
// PerDeviceNodeSelection defines whether the access from nodes to
// resources in the pool is set on the ResourceSlice level or on each

View File

@@ -1710,16 +1710,14 @@ func ForKind(kind schema.GroupVersionKind) interface{} {
return &applyconfigurationsresourcev1.ResourceSliceSpecApplyConfiguration{}
// Group=resource.k8s.io, Version=v1alpha3
case v1alpha3.SchemeGroupVersion.WithKind("CELDeviceSelector"):
return &resourcev1alpha3.CELDeviceSelectorApplyConfiguration{}
case v1alpha3.SchemeGroupVersion.WithKind("DeviceSelector"):
return &resourcev1alpha3.DeviceSelectorApplyConfiguration{}
case v1alpha3.SchemeGroupVersion.WithKind("DeviceTaint"):
return &resourcev1alpha3.DeviceTaintApplyConfiguration{}
case v1alpha3.SchemeGroupVersion.WithKind("DeviceTaintRule"):
return &resourcev1alpha3.DeviceTaintRuleApplyConfiguration{}
case v1alpha3.SchemeGroupVersion.WithKind("DeviceTaintRuleSpec"):
return &resourcev1alpha3.DeviceTaintRuleSpecApplyConfiguration{}
case v1alpha3.SchemeGroupVersion.WithKind("DeviceTaintRuleStatus"):
return &resourcev1alpha3.DeviceTaintRuleStatusApplyConfiguration{}
case v1alpha3.SchemeGroupVersion.WithKind("DeviceTaintSelector"):
return &resourcev1alpha3.DeviceTaintSelectorApplyConfiguration{}

2
go.mod
View File

@@ -24,7 +24,7 @@ require (
golang.org/x/time v0.9.0
google.golang.org/protobuf v1.36.8
gopkg.in/evanphx/json-patch.v4 v4.13.0
k8s.io/api v0.0.0-20251105002757-f67184811e04
k8s.io/api v0.0.0-20251105002758-78deebe13046
k8s.io/apimachinery v0.0.0-20251104194212-729c13d7df38
k8s.io/klog/v2 v2.130.1
k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912

4
go.sum
View File

@@ -123,8 +123,8 @@ gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
k8s.io/api v0.0.0-20251105002757-f67184811e04 h1:h2EwgSUX1vUMLirVigP+sveIiws767ZlzcHHpIY0LZk=
k8s.io/api v0.0.0-20251105002757-f67184811e04/go.mod h1:WAtHXlm214kKcYg1bP2G5eefhLoi/NCF6sxUeTjUXMs=
k8s.io/api v0.0.0-20251105002758-78deebe13046 h1:3pic1iEIudf2/BxAAnjrG563cHmOoRoXX54aUa49wcU=
k8s.io/api v0.0.0-20251105002758-78deebe13046/go.mod h1:WAtHXlm214kKcYg1bP2G5eefhLoi/NCF6sxUeTjUXMs=
k8s.io/apimachinery v0.0.0-20251104194212-729c13d7df38 h1:5jRAlNQwmLaPNhf9mfhacvZKFF8fE4nfULiBul0PrGM=
k8s.io/apimachinery v0.0.0-20251104194212-729c13d7df38/go.mod h1:dR9KPaf5L0t2p9jZg/wCGB4b3ma2sXZ2zdNqILs+Sak=
k8s.io/klog/v2 v2.130.1 h1:n9Xl7H1Xvksem4KFG4PYbdQCQxqc/tTUyrgXaOhHSzk=

View File

@@ -40,6 +40,8 @@ type DeviceTaintRulesGetter interface {
type DeviceTaintRuleInterface interface {
Create(ctx context.Context, deviceTaintRule *resourcev1alpha3.DeviceTaintRule, opts v1.CreateOptions) (*resourcev1alpha3.DeviceTaintRule, error)
Update(ctx context.Context, deviceTaintRule *resourcev1alpha3.DeviceTaintRule, opts v1.UpdateOptions) (*resourcev1alpha3.DeviceTaintRule, error)
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
UpdateStatus(ctx context.Context, deviceTaintRule *resourcev1alpha3.DeviceTaintRule, opts v1.UpdateOptions) (*resourcev1alpha3.DeviceTaintRule, error)
Delete(ctx context.Context, name string, opts v1.DeleteOptions) error
DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error
Get(ctx context.Context, name string, opts v1.GetOptions) (*resourcev1alpha3.DeviceTaintRule, error)
@@ -47,6 +49,8 @@ type DeviceTaintRuleInterface interface {
Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error)
Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *resourcev1alpha3.DeviceTaintRule, err error)
Apply(ctx context.Context, deviceTaintRule *applyconfigurationsresourcev1alpha3.DeviceTaintRuleApplyConfiguration, opts v1.ApplyOptions) (result *resourcev1alpha3.DeviceTaintRule, err error)
// Add a +genclient:noStatus comment above the type to avoid generating ApplyStatus().
ApplyStatus(ctx context.Context, deviceTaintRule *applyconfigurationsresourcev1alpha3.DeviceTaintRuleApplyConfiguration, opts v1.ApplyOptions) (result *resourcev1alpha3.DeviceTaintRule, err error)
DeviceTaintRuleExpansion
}