diff --git a/Makefile b/Makefile index 74fe9b28b..149efc5ed 100644 --- a/Makefile +++ b/Makefile @@ -23,7 +23,7 @@ GOBIN_DIR=$(abspath ./bin ) PATH := $(GOBIN_DIR):$(TOOLS_GOBIN_DIR):$(PATH) TMPDIR := $(shell mktemp -d) -CODE_GENERATOR_VER := v2.4.0 +CODE_GENERATOR_VER := f78b79a2f905778087cbd266cda10d47997f0bdf CODE_GENERATOR_BIN := code-generator CODE_GENERATOR := $(TOOLS_DIR)/$(CODE_GENERATOR_BIN)-$(CODE_GENERATOR_VER) export CODE_GENERATOR # so hack scripts can use it diff --git a/apiextensions/listers/apiextensions/v1/customresourcedefinition_expansion.go b/apiextensions/listers/apiextensions/v1/customresourcedefinition_expansion.go index 0ec8ae5e7..83f3da029 100644 --- a/apiextensions/listers/apiextensions/v1/customresourcedefinition_expansion.go +++ b/apiextensions/listers/apiextensions/v1/customresourcedefinition_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/apiextensions/listers/apiextensions/v1beta1/customresourcedefinition_expansion.go b/apiextensions/listers/apiextensions/v1beta1/customresourcedefinition_expansion.go index aa4933a72..92dccdcb6 100644 --- a/apiextensions/listers/apiextensions/v1beta1/customresourcedefinition_expansion.go +++ b/apiextensions/listers/apiextensions/v1beta1/customresourcedefinition_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/go.mod b/go.mod index 7d217408e..1fb6bb526 100644 --- a/go.mod +++ b/go.mod @@ -1,94 +1,89 @@ module github.com/kcp-dev/client-go -go 1.23.0 +go 1.22.0 require ( github.com/evanphx/json-patch v5.6.0+incompatible - github.com/google/gnostic-models v0.6.9 - github.com/kcp-dev/apimachinery/v2 v2.0.1-0.20250207161408-e1833e4a94f2 + github.com/google/gnostic-models v0.6.8 + github.com/kcp-dev/apimachinery/v2 v2.0.1-0.20250223115924-431177b024f3 github.com/kcp-dev/logicalcluster/v3 v3.0.5 - k8s.io/api v0.32.0 - k8s.io/apiextensions-apiserver v0.32.0 - k8s.io/apimachinery v0.32.0 - k8s.io/client-go v0.32.0 + k8s.io/api v0.31.6 + k8s.io/apiextensions-apiserver v0.31.6 + k8s.io/apimachinery v0.31.6 + k8s.io/client-go v0.31.6 k8s.io/klog/v2 v2.130.1 ) require ( - cel.dev/expr v0.19.1 // indirect - github.com/antlr4-go/antlr/v4 v4.13.1 // indirect + github.com/antlr4-go/antlr/v4 v4.13.0 // indirect github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/blang/semver/v4 v4.0.0 // indirect github.com/cenkalti/backoff/v4 v4.3.0 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect - github.com/emicklei/go-restful/v3 v3.12.1 // indirect + github.com/emicklei/go-restful/v3 v3.11.0 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect github.com/fxamacker/cbor/v2 v2.7.0 // indirect github.com/go-logr/logr v1.4.2 // indirect github.com/go-logr/stdr v1.2.2 // indirect - github.com/go-openapi/jsonpointer v0.21.0 // indirect - github.com/go-openapi/jsonreference v0.21.0 // indirect - github.com/go-openapi/swag v0.23.0 // indirect + github.com/go-openapi/jsonpointer v0.19.6 // indirect + github.com/go-openapi/jsonreference v0.20.2 // indirect + github.com/go-openapi/swag v0.22.4 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/protobuf v1.5.4 // indirect - github.com/google/btree v1.1.3 // indirect - github.com/google/cel-go v0.22.1 // indirect + github.com/google/cel-go v0.20.1 // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/google/gofuzz v1.2.0 // indirect github.com/google/uuid v1.6.0 // indirect - github.com/grpc-ecosystem/grpc-gateway/v2 v2.25.1 // indirect + github.com/grpc-ecosystem/grpc-gateway/v2 v2.20.0 // indirect + github.com/imdario/mergo v0.3.6 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/josharian/intern v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect - github.com/klauspost/compress v1.17.11 // indirect - github.com/mailru/easyjson v0.9.0 // indirect + github.com/mailru/easyjson v0.7.7 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/pkg/errors v0.9.1 // indirect - github.com/prometheus/client_golang v1.20.5 // indirect + github.com/prometheus/client_golang v1.19.1 // indirect github.com/prometheus/client_model v0.6.1 // indirect - github.com/prometheus/common v0.61.0 // indirect + github.com/prometheus/common v0.55.0 // indirect github.com/prometheus/procfs v0.15.1 // indirect github.com/spf13/cobra v1.8.1 // indirect github.com/spf13/pflag v1.0.5 // indirect - github.com/stoewer/go-strcase v1.3.0 // indirect + github.com/stoewer/go-strcase v1.2.0 // indirect github.com/x448/float16 v0.8.4 // indirect - go.etcd.io/etcd/client/pkg/v3 v3.5.17 // indirect - go.etcd.io/etcd/client/v3 v3.5.17 // indirect - go.opentelemetry.io/auto/sdk v1.1.0 // indirect - go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.58.0 // indirect - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.58.0 // indirect - go.opentelemetry.io/otel v1.33.0 // indirect - go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.33.0 // indirect - go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.33.0 // indirect - go.opentelemetry.io/otel/metric v1.33.0 // indirect - go.opentelemetry.io/otel/sdk v1.33.0 // indirect - go.opentelemetry.io/otel/trace v1.33.0 // indirect - go.opentelemetry.io/proto/otlp v1.5.0 // indirect - golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8 // indirect - golang.org/x/net v0.34.0 // indirect - golang.org/x/oauth2 v0.25.0 // indirect - golang.org/x/sync v0.10.0 // indirect - golang.org/x/sys v0.29.0 // indirect - golang.org/x/term v0.28.0 // indirect - golang.org/x/text v0.21.0 // indirect - golang.org/x/time v0.9.0 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20250106144421-5f5ef82da422 // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20250106144421-5f5ef82da422 // indirect - google.golang.org/grpc v1.69.2 // indirect - google.golang.org/protobuf v1.36.2 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.53.0 // indirect + go.opentelemetry.io/otel v1.28.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.28.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.27.0 // indirect + go.opentelemetry.io/otel/metric v1.28.0 // indirect + go.opentelemetry.io/otel/sdk v1.28.0 // indirect + go.opentelemetry.io/otel/trace v1.28.0 // indirect + go.opentelemetry.io/proto/otlp v1.3.1 // indirect + golang.org/x/exp v0.0.0-20230515195305-f3d0a9c9a5cc // indirect + golang.org/x/net v0.26.0 // indirect + golang.org/x/oauth2 v0.21.0 // indirect + golang.org/x/sync v0.7.0 // indirect + golang.org/x/sys v0.21.0 // indirect + golang.org/x/term v0.21.0 // indirect + golang.org/x/text v0.16.0 // indirect + golang.org/x/time v0.3.0 // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20240528184218-531527333157 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20240701130421-f6361c86f094 // indirect + google.golang.org/grpc v1.65.0 // indirect + google.golang.org/protobuf v1.34.2 // indirect gopkg.in/evanphx/json-patch.v4 v4.12.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect + gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/apiserver v0.32.0 // indirect - k8s.io/component-base v0.32.0 // indirect - k8s.io/kube-openapi v0.0.0-20241212222426-2c72e554b1e7 // indirect - k8s.io/utils v0.0.0-20241210054802-24370beab758 // indirect - sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.1 // indirect - sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8 // indirect - sigs.k8s.io/structured-merge-diff/v4 v4.5.0 // indirect + k8s.io/apiserver v0.31.6 // indirect + k8s.io/component-base v0.31.6 // indirect + k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340 // indirect + k8s.io/utils v0.0.0-20240711033017-18e509b52bc8 // indirect + sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.30.3 // indirect + sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect + sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect sigs.k8s.io/yaml v1.4.0 // indirect ) diff --git a/go.sum b/go.sum index 031a2964c..c874de87e 100644 --- a/go.sum +++ b/go.sum @@ -1,7 +1,5 @@ -cel.dev/expr v0.19.1 h1:NciYrtDRIR0lNCnH1LFJegdjspNx9fI59O7TWcua/W4= -cel.dev/expr v0.19.1/go.mod h1:MrpN08Q+lEBs+bGYdLxxHkZoUSsCp0nSKTs0nTymJgw= -github.com/antlr4-go/antlr/v4 v4.13.1 h1:SqQKkuVZ+zWkMMNkjy5FZe5mr5WURWnlpmOuzYWrPrQ= -github.com/antlr4-go/antlr/v4 v4.13.1/go.mod h1:GKmUxMtwp6ZgGwZSva4eWPC5mS6vUAmOABFgjdkM7Nw= +github.com/antlr4-go/antlr/v4 v4.13.0 h1:lxCg3LAv+EUK6t1i0y1V6/SLeUi0eKEKdhQAlS8TVTI= +github.com/antlr4-go/antlr/v4 v4.13.0/go.mod h1:pfChB/xh/Unjila75QW7+VU4TSnWnnk9UTnmpPaOR2g= github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a h1:idn718Q4B6AGu/h5Sxe66HYVdqdGu2l9Iebqhi/AEoA= github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:lB+ZfQJz7igIIfQNfa7Ml4HSf2uFQQRzpGGRXenZAgY= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= @@ -17,12 +15,13 @@ github.com/coreos/go-semver v0.3.1/go.mod h1:irMmmIw/7yzSRPWryHsK7EYSg09caPQL03V github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs= github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/cpuguy83/go-md2man/v2 v2.0.4/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/emicklei/go-restful/v3 v3.12.1 h1:PJMDIM/ak7btuL8Ex0iYET9hxM3CI2sjZtzpL63nKAU= -github.com/emicklei/go-restful/v3 v3.12.1/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= +github.com/emicklei/go-restful/v3 v3.11.0 h1:rAQeMHw1c7zTmncogyy8VvRZwtkmkZ4FxERmMY4rD+g= +github.com/emicklei/go-restful/v3 v3.11.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= github.com/evanphx/json-patch v5.6.0+incompatible h1:jBYDEEiFBPxA0v50tFdvOzQQTCvpL6mnFh5mB2/l16U= github.com/evanphx/json-patch v5.6.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= @@ -34,60 +33,60 @@ github.com/go-logr/logr v1.4.2 h1:6pFjapn8bFcIbiKo3XT4j/BhANplGihG6tvd+8rYgrY= github.com/go-logr/logr v1.4.2/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= -github.com/go-openapi/jsonpointer v0.21.0 h1:YgdVicSA9vH5RiHs9TZW5oyafXZFc6+2Vc1rr/O9oNQ= -github.com/go-openapi/jsonpointer v0.21.0/go.mod h1:IUyH9l/+uyhIYQ/PXVA41Rexl+kOkAPDdXEYns6fzUY= -github.com/go-openapi/jsonreference v0.21.0 h1:Rs+Y7hSXT83Jacb7kFyjn4ijOuVGSvOdF2+tg1TRrwQ= -github.com/go-openapi/jsonreference v0.21.0/go.mod h1:LmZmgsrTkVg9LG4EaHeY8cBDslNPMo06cago5JNLkm4= -github.com/go-openapi/swag v0.23.0 h1:vsEVJDUo2hPJ2tu0/Xc+4noaxyEffXNIs3cOULZ+GrE= -github.com/go-openapi/swag v0.23.0/go.mod h1:esZ8ITTYEsH1V2trKHjAN8Ai7xHb8RV+YSZ577vPjgQ= +github.com/go-openapi/jsonpointer v0.19.6 h1:eCs3fxoIi3Wh6vtgmLTOjdhSpiqphQ+DaPn38N2ZdrE= +github.com/go-openapi/jsonpointer v0.19.6/go.mod h1:osyAmYz/mB/C3I+WsTTSgw1ONzaLJoLCyoi6/zppojs= +github.com/go-openapi/jsonreference v0.20.2 h1:3sVjiK66+uXK/6oQ8xgcRKcFgQ5KXa2KvnJRumpMGbE= +github.com/go-openapi/jsonreference v0.20.2/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En5Ap4rVB5KVcIDZG2k= +github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= +github.com/go-openapi/swag v0.22.4 h1:QLMzNJnMGPRNDCbySlcj1x01tzU8/9LTTL9hZZZogBU= +github.com/go-openapi/swag v0.22.4/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= github.com/go-task/slim-sprig/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI= github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= -github.com/google/btree v1.1.3 h1:CVpQJjYgC4VbzxeGVHfvZrv1ctoYCAI8vbl07Fcxlyg= -github.com/google/btree v1.1.3/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= -github.com/google/cel-go v0.22.1 h1:AfVXx3chM2qwoSbM7Da8g8hX8OVSkBFwX+rz2+PcK40= -github.com/google/cel-go v0.22.1/go.mod h1:BuznPXXfQDpXKWQ9sPW3TzlAJN5zzFe+i9tIs0yC4s8= -github.com/google/gnostic-models v0.6.9 h1:MU/8wDLif2qCXZmzncUQ/BOfxWfthHi63KqpoNbWqVw= -github.com/google/gnostic-models v0.6.9/go.mod h1:CiWsm0s6BSQd1hRn8/QmxqB6BesYcbSZxsz9b0KuDBw= +github.com/google/cel-go v0.20.1 h1:nDx9r8S3L4pE61eDdt8igGj8rf5kjYR3ILxWIpWNi84= +github.com/google/cel-go v0.20.1/go.mod h1:kWcIzTsPX0zmQ+H3TirHstLLf9ep5QTsZBN9u4dOYLg= +github.com/google/gnostic-models v0.6.8 h1:yo/ABAfM5IMRsS1VnXjTBvUb61tFIHozhlYvRgGre9I= +github.com/google/gnostic-models v0.6.8/go.mod h1:5n7qKqH0f5wFt+aWF8CW6pZLLNOfYuF5OpfBSENuI8U= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db h1:097atOisP2aRj7vFgYQBbFN4U4JNXUNYpxael3UzMyo= -github.com/google/pprof v0.0.0-20241029153458-d1b30febd7db/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= +github.com/google/pprof v0.0.0-20240525223248-4bfdf5a9a2af h1:kmjWCqn2qkEml422C2Rrd27c3VGxi6a/6HNq8QmHRKM= +github.com/google/pprof v0.0.0-20240525223248-4bfdf5a9a2af/go.mod h1:K1liHPHnj73Fdn/EKuT8nrFqBihUSKXoLYU0BuatOYo= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 h1:Ovs26xHkKqVztRpIrF/92BcuyuQ/YW4NSIpoGtfXNho= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.25.1 h1:VNqngBF40hVlDloBruUehVYC3ArSgIyScOAyMRqBxRg= -github.com/grpc-ecosystem/grpc-gateway/v2 v2.25.1/go.mod h1:RBRO7fro65R6tjKzYgLAFo0t1QEXY1Dp+i/bvpRiqiQ= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.20.0 h1:bkypFPDjIYGfCYD5mRBvpqxfYX1YCS1PXdKYWi8FsN0= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.20.0/go.mod h1:P+Lt/0by1T8bfcF3z737NnSbmxQAppXMRziHUxPOC8k= +github.com/imdario/mergo v0.3.6 h1:xTNEAn+kxVO7dTZGu0CegyqKZmoWFI0rF8UxjlB2d28= +github.com/imdario/mergo v0.3.6/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= -github.com/kcp-dev/apimachinery/v2 v2.0.1-0.20250207161408-e1833e4a94f2 h1:6MeV6CBJhNxF3DhkdwhcqeyEc8Al2MGeKFNA0O95icc= -github.com/kcp-dev/apimachinery/v2 v2.0.1-0.20250207161408-e1833e4a94f2/go.mod h1:jnMZxVnCuKlkIXc4J1Qtmy1Lyo171CDF/RQhNAo0tvA= +github.com/kcp-dev/apimachinery/v2 v2.0.1-0.20250223115924-431177b024f3 h1:YwNX7ZIpQXg9u5vav/fobmf4nnO0WhbELWaL3X74Oe4= +github.com/kcp-dev/apimachinery/v2 v2.0.1-0.20250223115924-431177b024f3/go.mod h1:n0+EV+LGKl1MXXqGbGcn0AaBv7hdKsdazSYuq8nM8Us= github.com/kcp-dev/logicalcluster/v3 v3.0.5 h1:JbYakokb+5Uinz09oTXomSUJVQsqfxEvU4RyHUYxHOU= github.com/kcp-dev/logicalcluster/v3 v3.0.5/go.mod h1:EWBUBxdr49fUB1cLMO4nOdBWmYifLbP1LfoL20KkXYY= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/klauspost/compress v1.17.11 h1:In6xLpyWOi1+C7tXUUWv2ot1QvBjxevKAaI6IXrJmUc= -github.com/klauspost/compress v1.17.11/go.mod h1:pMDklpSncoRMuLFrf1W9Ss9KT+0rH90U12bZKk7uwG0= +github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= +github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= +github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= -github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= -github.com/mailru/easyjson v0.9.0 h1:PrnmzHw7262yW8sTBwxi1PdJA3Iw/EKBa8psRf7d9a4= -github.com/mailru/easyjson v0.9.0/go.mod h1:1+xMtQp2MRNVL/V1bOzuP3aP8VNwRW55fQUto+XFtTU= +github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= +github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -95,130 +94,127 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= -github.com/onsi/ginkgo/v2 v2.21.0 h1:7rg/4f3rB88pb5obDgNZrNHrQ4e6WpjonchcpuBRnZM= -github.com/onsi/ginkgo/v2 v2.21.0/go.mod h1:7Du3c42kxCUegi0IImZ1wUQzMBVecgIHjR1C+NkhLQo= -github.com/onsi/gomega v1.35.1 h1:Cwbd75ZBPxFSuZ6T+rN/WCb/gOc6YgFBXLlZLhC7Ds4= -github.com/onsi/gomega v1.35.1/go.mod h1:PvZbdDc8J6XJEpDK4HCuRBm8a6Fzp9/DmhC9C7yFlog= +github.com/onsi/ginkgo/v2 v2.19.0 h1:9Cnnf7UHo57Hy3k6/m5k3dRfGTMXGvxhHFvkDTCTpvA= +github.com/onsi/ginkgo/v2 v2.19.0/go.mod h1:rlwLi9PilAFJ8jCg9UE1QP6VBpd6/xj3SRC0d6TU0To= +github.com/onsi/gomega v1.33.1 h1:dsYjIxxSR755MDmKVsaFQTE22ChNBcuuTWgkUDSubOk= +github.com/onsi/gomega v1.33.1/go.mod h1:U4R44UsT+9eLIaYRB2a5qajjtQYn0hauxvRm16AVYg0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/prometheus/client_golang v1.20.5 h1:cxppBPuYhUnsO6yo/aoRol4L7q7UFfdm+bR9r+8l63Y= -github.com/prometheus/client_golang v1.20.5/go.mod h1:PIEt8X02hGcP8JWbeHyeZ53Y/jReSnHgO035n//V5WE= +github.com/prometheus/client_golang v1.19.1 h1:wZWJDwK+NameRJuPGDhlnFgx8e8HN3XHQeLaYJFJBOE= +github.com/prometheus/client_golang v1.19.1/go.mod h1:mP78NwGzrVks5S2H6ab8+ZZGJLZUq1hoULYBAYBw1Ho= github.com/prometheus/client_model v0.6.1 h1:ZKSh/rekM+n3CeS952MLRAdFwIKqeY8b62p8ais2e9E= github.com/prometheus/client_model v0.6.1/go.mod h1:OrxVMOVHjw3lKMa8+x6HeMGkHMQyHDk9E3jmP2AmGiY= -github.com/prometheus/common v0.61.0 h1:3gv/GThfX0cV2lpO7gkTUwZru38mxevy90Bj8YFSRQQ= -github.com/prometheus/common v0.61.0/go.mod h1:zr29OCN/2BsJRaFwG8QOBr41D6kkchKbpeNH7pAjb/s= +github.com/prometheus/common v0.55.0 h1:KEi6DK7lXW/m7Ig5i47x0vRzuBsHuvJdi5ee6Y3G1dc= +github.com/prometheus/common v0.55.0/go.mod h1:2SECS4xJG1kd8XF9IcM1gMX6510RAEL65zxzNImwdc8= github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0learggepc= github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk= -github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR38lUII= -github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o= +github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= +github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/spf13/cobra v1.8.1 h1:e5/vxKd/rZsfSJMUX1agtjeTDf+qv1/JdBF8gg5k9ZM= github.com/spf13/cobra v1.8.1/go.mod h1:wHxEcudfqmLYa8iTfL+OuZPbBZkmvliBWKIezN3kD9Y= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/stoewer/go-strcase v1.3.0 h1:g0eASXYtp+yvN9fK8sH94oCIk0fau9uV1/ZdJ0AVEzs= -github.com/stoewer/go-strcase v1.3.0/go.mod h1:fAH5hQ5pehh+j3nZfvwdk2RgEgQjAoM8wodgtPmh1xo= +github.com/stoewer/go-strcase v1.2.0 h1:Z2iHWqGXH00XYgqDmNgQbIBxf3wrNq0F3feEy0ainaU= +github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= +github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= -github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/x448/float16 v0.8.4 h1:qLwI1I70+NjRFUR3zs1JPUCgaCXSh3SW62uAKT1mSBM= github.com/x448/float16 v0.8.4/go.mod h1:14CWIYCyZA/cWjXOioeEpHeN/83MdbZDRQHoFcYsOfg= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= -go.etcd.io/etcd/api/v3 v3.5.17 h1:cQB8eb8bxwuxOilBpMJAEo8fAONyrdXTHUNcMd8yT1w= -go.etcd.io/etcd/api/v3 v3.5.17/go.mod h1:d1hvkRuXkts6PmaYk2Vrgqbv7H4ADfAKhyJqHNLJCB4= -go.etcd.io/etcd/client/pkg/v3 v3.5.17 h1:XxnDXAWq2pnxqx76ljWwiQ9jylbpC4rvkAeRVOUKKVw= -go.etcd.io/etcd/client/pkg/v3 v3.5.17/go.mod h1:4DqK1TKacp/86nJk4FLQqo6Mn2vvQFBmruW3pP14H/w= -go.etcd.io/etcd/client/v3 v3.5.17 h1:o48sINNeWz5+pjy/Z0+HKpj/xSnBkuVhVvXkjEXbqZY= -go.etcd.io/etcd/client/v3 v3.5.17/go.mod h1:j2d4eXTHWkT2ClBgnnEPm/Wuu7jsqku41v9DZ3OtjQo= -go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA= -go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.58.0 h1:PS8wXpbyaDJQ2VDHHncMe9Vct0Zn1fEjpsjrLxGJoSc= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.58.0/go.mod h1:HDBUsEjOuRC0EzKZ1bSaRGZWUBAzo+MhAcUUORSr4D0= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.58.0 h1:yd02MEjBdJkG3uabWP9apV+OuWRIXGDuJEUJbOHmCFU= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.58.0/go.mod h1:umTcuxiv1n/s/S6/c2AT/g2CQ7u5C59sHDNmfSwgz7Q= -go.opentelemetry.io/otel v1.33.0 h1:/FerN9bax5LoK51X/sI0SVYrjSE0/yUL7DpxW4K3FWw= -go.opentelemetry.io/otel v1.33.0/go.mod h1:SUUkR6csvUQl+yjReHu5uM3EtVV7MBm5FHKRlNx4I8I= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.33.0 h1:Vh5HayB/0HHfOQA7Ctx69E/Y/DcQSMPpKANYVMQ7fBA= -go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.33.0/go.mod h1:cpgtDBaqD/6ok/UG0jT15/uKjAY8mRA53diogHBg3UI= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.33.0 h1:5pojmb1U1AogINhN3SurB+zm/nIcusopeBNp42f45QM= -go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.33.0/go.mod h1:57gTHJSE5S1tqg+EKsLPlTWhpHMsWlVmer+LA926XiA= -go.opentelemetry.io/otel/metric v1.33.0 h1:r+JOocAyeRVXD8lZpjdQjzMadVZp2M4WmQ+5WtEnklQ= -go.opentelemetry.io/otel/metric v1.33.0/go.mod h1:L9+Fyctbp6HFTddIxClbQkjtubW6O9QS3Ann/M82u6M= -go.opentelemetry.io/otel/sdk v1.33.0 h1:iax7M131HuAm9QkZotNHEfstof92xM+N8sr3uHXc2IM= -go.opentelemetry.io/otel/sdk v1.33.0/go.mod h1:A1Q5oi7/9XaMlIWzPSxLRWOI8nG3FnzHJNbiENQuihM= -go.opentelemetry.io/otel/sdk/metric v1.31.0 h1:i9hxxLJF/9kkvfHppyLL55aW7iIJz4JjxTeYusH7zMc= -go.opentelemetry.io/otel/sdk/metric v1.31.0/go.mod h1:CRInTMVvNhUKgSAMbKyTMxqOBC0zgyxzW55lZzX43Y8= -go.opentelemetry.io/otel/trace v1.33.0 h1:cCJuF7LRjUFso9LPnEAHJDB2pqzp+hbO8eu1qqW2d/s= -go.opentelemetry.io/otel/trace v1.33.0/go.mod h1:uIcdVUZMpTAmz0tI1z04GoVSezK37CbGV4fr1f2nBck= -go.opentelemetry.io/proto/otlp v1.5.0 h1:xJvq7gMzB31/d406fB8U5CBdyQGw4P399D1aQWU/3i4= -go.opentelemetry.io/proto/otlp v1.5.0/go.mod h1:keN8WnHxOy8PG0rQZjJJ5A2ebUoafqWp0eVQ4yIXvJ4= +go.etcd.io/etcd/api/v3 v3.5.14 h1:vHObSCxyB9zlF60w7qzAdTcGaglbJOpSj1Xj9+WGxq0= +go.etcd.io/etcd/api/v3 v3.5.14/go.mod h1:BmtWcRlQvwa1h3G2jvKYwIQy4PkHlDej5t7uLMUdJUU= +go.etcd.io/etcd/client/pkg/v3 v3.5.14 h1:SaNH6Y+rVEdxfpA2Jr5wkEvN6Zykme5+YnbCkxvuWxQ= +go.etcd.io/etcd/client/pkg/v3 v3.5.14/go.mod h1:8uMgAokyG1czCtIdsq+AGyYQMvpIKnSvPjFMunkgeZI= +go.etcd.io/etcd/client/v3 v3.5.14 h1:CWfRs4FDaDoSz81giL7zPpZH2Z35tbOrAJkkjMqOupg= +go.etcd.io/etcd/client/v3 v3.5.14/go.mod h1:k3XfdV/VIHy/97rqWjoUzrj9tk7GgJGH9J8L4dNXmAk= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.53.0 h1:9G6E0TXzGFVfTnawRzrPl83iHOAV7L8NJiR8RSGYV1g= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.53.0/go.mod h1:azvtTADFQJA8mX80jIH/akaE7h+dbm/sVuaHqN13w74= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.53.0 h1:4K4tsIXefpVJtvA/8srF4V4y0akAoPHkIslgAkjixJA= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.53.0/go.mod h1:jjdQuTGVsXV4vSs+CJ2qYDeDPf9yIJV23qlIzBm73Vg= +go.opentelemetry.io/otel v1.28.0 h1:/SqNcYk+idO0CxKEUOtKQClMK/MimZihKYMruSMViUo= +go.opentelemetry.io/otel v1.28.0/go.mod h1:q68ijF8Fc8CnMHKyzqL6akLO46ePnjkgfIMIjUIX9z4= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.28.0 h1:3Q/xZUyC1BBkualc9ROb4G8qkH90LXEIICcs5zv1OYY= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.28.0/go.mod h1:s75jGIWA9OfCMzF0xr+ZgfrB5FEbbV7UuYo32ahUiFI= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.27.0 h1:qFffATk0X+HD+f1Z8lswGiOQYKHRlzfmdJm0wEaVrFA= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.27.0/go.mod h1:MOiCmryaYtc+V0Ei+Tx9o5S1ZjA7kzLucuVuyzBZloQ= +go.opentelemetry.io/otel/metric v1.28.0 h1:f0HGvSl1KRAU1DLgLGFjrwVyismPlnuU6JD6bOeuA5Q= +go.opentelemetry.io/otel/metric v1.28.0/go.mod h1:Fb1eVBFZmLVTMb6PPohq3TO9IIhUisDsbJoL/+uQW4s= +go.opentelemetry.io/otel/sdk v1.28.0 h1:b9d7hIry8yZsgtbmM0DKyPWMMUMlK9NEKuIG4aBqWyE= +go.opentelemetry.io/otel/sdk v1.28.0/go.mod h1:oYj7ClPUA7Iw3m+r7GeEjz0qckQRJK2B8zjcZEfu7Pg= +go.opentelemetry.io/otel/trace v1.28.0 h1:GhQ9cUuQGmNDd5BTCP2dAvv75RdMxEfTmYejp+lkx9g= +go.opentelemetry.io/otel/trace v1.28.0/go.mod h1:jPyXzNPg6da9+38HEwElrQiHlVMTnVfM3/yv2OlIHaI= +go.opentelemetry.io/proto/otlp v1.3.1 h1:TrMUixzpM0yuc/znrFTP9MMRh8trP93mkCiDVeXrui0= +go.opentelemetry.io/proto/otlp v1.3.1/go.mod h1:0X1WI4de4ZsLrrJNLAQbFeLCm3T7yBkR0XqQ7niQU+8= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= go.uber.org/multierr v1.11.0 h1:blXXJkSxSSfBVBlC76pxqeO+LN3aDfLQo+309xJstO0= go.uber.org/multierr v1.11.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= -go.uber.org/zap v1.27.0 h1:aJMhYGrd5QSmlpLMr2MftRKl7t8J8PTZPA732ud/XR8= -go.uber.org/zap v1.27.0/go.mod h1:GB2qFLM7cTU87MWRP2mPIjqfIDnGu+VIO4V/SdhGo2E= +go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= +go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8 h1:yqrTHse8TCMW1M1ZCP+VAR/l0kKxwaAIqN/il7x4voA= -golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8/go.mod h1:tujkw807nyEEAamNbDrEGzRav+ilXA7PCRAd6xsmwiU= +golang.org/x/exp v0.0.0-20230515195305-f3d0a9c9a5cc h1:mCRnTeVUjcrhlRmO0VK8a6k6Rrf6TF9htwo2pJVSjIU= +golang.org/x/exp v0.0.0-20230515195305-f3d0a9c9a5cc/go.mod h1:V1LtkGg67GoY2N1AnLN78QLrzxkLyJw7RJb1gzOOz9w= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.34.0 h1:Mb7Mrk043xzHgnRM88suvJFwzVrRfHEHJEl5/71CKw0= -golang.org/x/net v0.34.0/go.mod h1:di0qlW3YNM5oh6GqDGQr92MyTozJPmybPK4Ev/Gm31k= -golang.org/x/oauth2 v0.25.0 h1:CY4y7XT9v0cRI9oupztF8AgiIu99L/ksR/Xp/6jrZ70= -golang.org/x/oauth2 v0.25.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= +golang.org/x/net v0.26.0 h1:soB7SVo0PWrY4vPW/+ay0jKDNScG2X9wFeYlXIvJsOQ= +golang.org/x/net v0.26.0/go.mod h1:5YKkiSynbBIh3p6iOc/vibscux0x38BZDkn8sCUPxHE= +golang.org/x/oauth2 v0.21.0 h1:tsimM75w1tF/uws5rbeHzIWxEqElMehnc+iW793zsZs= +golang.org/x/oauth2 v0.21.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.10.0 h1:3NQrjDixjgGwUOCaF8w2+VYHv0Ve/vGYSbdkTa98gmQ= -golang.org/x/sync v0.10.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sync v0.7.0 h1:YsImfSBoP9QPYL0xyKJPq0gcaJdG3rInoqxTWbfQu9M= +golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.29.0 h1:TPYlXGxvx1MGTn2GiZDhnjPA9wZzZeGKHHmKhHYvgaU= -golang.org/x/sys v0.29.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/term v0.28.0 h1:/Ts8HFuMR2E6IP/jlo7QVLZHggjKQbhu/7H0LJFr3Gg= -golang.org/x/term v0.28.0/go.mod h1:Sw/lC2IAUZ92udQNf3WodGtn4k/XoLyZoh8v/8uiwek= +golang.org/x/sys v0.21.0 h1:rF+pYz3DAGSQAxAu1CbC7catZg4ebC4UIeIhKxBZvws= +golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/term v0.21.0 h1:WVXCp+/EBEHOj53Rvu+7KiT/iElMrO8ACK16SMZ3jaA= +golang.org/x/term v0.21.0/go.mod h1:ooXLefLobQVslOqselCNF4SxFAaoS6KujMbsGzSDmX0= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.21.0 h1:zyQAAkrwaneQ066sspRyJaG9VNi/YJ1NfzcGB3hZ/qo= -golang.org/x/text v0.21.0/go.mod h1:4IBbMaMmOPCJ8SecivzSH54+73PCFmPWxNTLm+vZkEQ= -golang.org/x/time v0.9.0 h1:EsRrnYcQiGH+5FfbgvV4AP7qEZstoyrHB0DzarOQ4ZY= -golang.org/x/time v0.9.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= +golang.org/x/text v0.16.0 h1:a94ExnEXNtEwYLGJSIUxnWoxoRz/ZcCsV63ROupILh4= +golang.org/x/text v0.16.0/go.mod h1:GhwF1Be+LQoKShO3cGOHzqOgRrGaYc9AvblQOmPVHnI= +golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= +golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.29.0 h1:Xx0h3TtM9rzQpQuR4dKLrdglAmCEN5Oi+P74JdhdzXE= -golang.org/x/tools v0.29.0/go.mod h1:KMQVMRsVxU6nHCFXrBPhDB8XncLNLM0lIy/F14RP588= +golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d h1:vU5i/LfpvrRCpgM/VPfJLg5KjxD3E+hfT1SH+d9zLwg= +golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d/go.mod h1:aiJjzUbINMkxbQROHiO6hDPo2LHcIPhhQsa9DLh0yGk= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/genproto/googleapis/api v0.0.0-20250106144421-5f5ef82da422 h1:GVIKPyP/kLIyVOgOnTwFOrvQaQUzOzGMCxgFUOEmm24= -google.golang.org/genproto/googleapis/api v0.0.0-20250106144421-5f5ef82da422/go.mod h1:b6h1vNKhxaSoEI+5jc3PJUCustfli/mRab7295pY7rw= -google.golang.org/genproto/googleapis/rpc v0.0.0-20250106144421-5f5ef82da422 h1:3UsHvIr4Wc2aW4brOaSCmcxh9ksica6fHEr8P1XhkYw= -google.golang.org/genproto/googleapis/rpc v0.0.0-20250106144421-5f5ef82da422/go.mod h1:3ENsm/5D1mzDyhpzeRi1NR784I0BcofWBoSc5QqqMK4= -google.golang.org/grpc v1.69.2 h1:U3S9QEtbXC0bYNvRtcoklF3xGtLViumSYxWykJS+7AU= -google.golang.org/grpc v1.69.2/go.mod h1:vyjdE6jLBI76dgpDojsFGNaHlxdjXN9ghpnd2o7JGZ4= -google.golang.org/protobuf v1.36.2 h1:R8FeyR1/eLmkutZOM5CWghmo5itiG9z0ktFlTVLuTmU= -google.golang.org/protobuf v1.36.2/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= +google.golang.org/genproto/googleapis/api v0.0.0-20240528184218-531527333157 h1:7whR9kGa5LUwFtpLm2ArCEejtnxlGeLbAyjFY8sGNFw= +google.golang.org/genproto/googleapis/api v0.0.0-20240528184218-531527333157/go.mod h1:99sLkeliLXfdj2J75X3Ho+rrVCaJze0uwN7zDDkjPVU= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240701130421-f6361c86f094 h1:BwIjyKYGsK9dMCBOorzRri8MQwmi7mT9rGHsCEinZkA= +google.golang.org/genproto/googleapis/rpc v0.0.0-20240701130421-f6361c86f094/go.mod h1:Ue6ibwXGpU+dqIcODieyLOcgj7z8+IcskoNIgZxtrFY= +google.golang.org/grpc v1.65.0 h1:bs/cUb4lp1G5iImFFd3u5ixQzweKizoZJAwBNLR42lc= +google.golang.org/grpc v1.65.0/go.mod h1:WgYC2ypjlB0EiQi6wdKixMqukr6lBc0Vo+oOgjrM5ZQ= +google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= +google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= @@ -226,32 +222,36 @@ gopkg.in/evanphx/json-patch.v4 v4.12.0 h1:n6jtcsulIzXPJaxegRbvFNNrZDjbij7ny3gmSP gopkg.in/evanphx/json-patch.v4 v4.12.0/go.mod h1:p8EYWUEYMpynmqDbY58zCKCFZw8pRWMG4EsWvDvM72M= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= +gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= +gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= 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.32.0 h1:OL9JpbvAU5ny9ga2fb24X8H6xQlVp+aJMFlgtQjR9CE= -k8s.io/api v0.32.0/go.mod h1:4LEwHZEf6Q/cG96F3dqR965sYOfmPM7rq81BLgsE0p0= -k8s.io/apiextensions-apiserver v0.32.0 h1:S0Xlqt51qzzqjKPxfgX1xh4HBZE+p8KKBq+k2SWNOE0= -k8s.io/apiextensions-apiserver v0.32.0/go.mod h1:86hblMvN5yxMvZrZFX2OhIHAuFIMJIZ19bTvzkP+Fmw= -k8s.io/apimachinery v0.32.0 h1:cFSE7N3rmEEtv4ei5X6DaJPHHX0C+upp+v5lVPiEwpg= -k8s.io/apimachinery v0.32.0/go.mod h1:GpHVgxoKlTxClKcteaeuF1Ul/lDVb74KpZcxcmLDElE= -k8s.io/apiserver v0.32.0 h1:VJ89ZvQZ8p1sLeiWdRJpRD6oLozNZD2+qVSLi+ft5Qs= -k8s.io/apiserver v0.32.0/go.mod h1:HFh+dM1/BE/Hm4bS4nTXHVfN6Z6tFIZPi649n83b4Ag= -k8s.io/client-go v0.32.0 h1:DimtMcnN/JIKZcrSrstiwvvZvLjG0aSxy8PxN8IChp8= -k8s.io/client-go v0.32.0/go.mod h1:boDWvdM1Drk4NJj/VddSLnx59X3OPgwrOo0vGbtq9+8= -k8s.io/component-base v0.32.0 h1:d6cWHZkCiiep41ObYQS6IcgzOUQUNpywm39KVYaUqzU= -k8s.io/component-base v0.32.0/go.mod h1:JLG2W5TUxUu5uDyKiH2R/7NnxJo1HlPoRIIbVLkK5eM= +k8s.io/api v0.31.6 h1:ocWG/UhC9Mqp5oEfYWy9wCddbZiZyBAFTlBt0LVlhDg= +k8s.io/api v0.31.6/go.mod h1:i16xSiKMgVIVhsJMxfWq0mJbXA+Z7KhjPgYmwT41hl4= +k8s.io/apiextensions-apiserver v0.31.6 h1:v9sqyWlrgFZpAPdEb/bEiXfM98TfSppwRF0X/uWKXh0= +k8s.io/apiextensions-apiserver v0.31.6/go.mod h1:QVH3CFwqzGZtwsxPYzJlA/Qiwgb5FXmRMGls3CjzvbI= +k8s.io/apimachinery v0.31.6 h1:Pn96A0wHD0X8+l7QTdAzdLQPrpav1s8rU6A+v2/9UEY= +k8s.io/apimachinery v0.31.6/go.mod h1:rsPdaZJfTfLsNJSQzNHQvYoTmxhoOEofxtOsF3rtsMo= +k8s.io/apiserver v0.31.6 h1:FEhEGLsz1PbMOHeQZDbOUlMh36zRZbjgKwJCoMhdGmw= +k8s.io/apiserver v0.31.6/go.mod h1:dpFh+xqFQ02O8vLYCIqoiV7sJIpZsUULeNuag6Y9HGo= +k8s.io/client-go v0.31.6 h1:51HT40qVIZ13BrHKeWxFuU52uoPnFhxTYJnv4+LTgp4= +k8s.io/client-go v0.31.6/go.mod h1:MEq7JQJelUQ0/4fMoPEUrc/OOFyGo/9LmGA38H6O6xY= +k8s.io/component-base v0.31.6 h1:FgI25PuZtCp2n7AFpOaDpMQOLieFdrpAbpeoZu7VhDI= +k8s.io/component-base v0.31.6/go.mod h1:aVRrh8lAI1kSShFmwcKLhc3msQoUcmFWPBDf0sXaISM= k8s.io/klog/v2 v2.130.1 h1:n9Xl7H1Xvksem4KFG4PYbdQCQxqc/tTUyrgXaOhHSzk= k8s.io/klog/v2 v2.130.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE= -k8s.io/kube-openapi v0.0.0-20241212222426-2c72e554b1e7 h1:hcha5B1kVACrLujCKLbr8XWMxCxzQx42DY8QKYJrDLg= -k8s.io/kube-openapi v0.0.0-20241212222426-2c72e554b1e7/go.mod h1:GewRfANuJ70iYzvn+i4lezLDAFzvjxZYK1gn1lWcfas= -k8s.io/utils v0.0.0-20241210054802-24370beab758 h1:sdbE21q2nlQtFh65saZY+rRM6x6aJJI8IUa1AmH/qa0= -k8s.io/utils v0.0.0-20241210054802-24370beab758/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= -sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.1 h1:uOuSLOMBWkJH0TWa9X6l+mj5nZdm6Ay6Bli8HL8rNfk= -sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.31.1/go.mod h1:Ve9uj1L+deCXFrPOk1LpFXqTg7LCFzFso6PA48q/XZw= -sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8 h1:gBQPwqORJ8d8/YNZWEjoZs7npUVDpVXUUOFfW6CgAqE= -sigs.k8s.io/json v0.0.0-20241014173422-cfa47c3a1cc8/go.mod h1:mdzfpAEoE6DHQEN0uh9ZbOCuHbLK5wOm7dK4ctXE9Tg= -sigs.k8s.io/structured-merge-diff/v4 v4.5.0 h1:nbCitCK2hfnhyiKo6uf2HxUPTCodY6Qaf85SbDIaMBk= -sigs.k8s.io/structured-merge-diff/v4 v4.5.0/go.mod h1:N8f93tFZh9U6vpxwRArLiikrE5/2tiu1w1AGfACIGE4= +k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340 h1:BZqlfIlq5YbRMFko6/PM7FjZpUb45WallggurYhKGag= +k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340/go.mod h1:yD4MZYeKMBwQKVht279WycxKyM84kkAx2DPrTXaeb98= +k8s.io/utils v0.0.0-20240711033017-18e509b52bc8 h1:pUdcCO1Lk/tbT5ztQWOBi5HBgbBP1J8+AsQnQCKsi8A= +k8s.io/utils v0.0.0-20240711033017-18e509b52bc8/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.30.3 h1:2770sDpzrjjsAtVhSeUFseziht227YAWYHLGNM8QPwY= +sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.30.3/go.mod h1:Ve9uj1L+deCXFrPOk1LpFXqTg7LCFzFso6PA48q/XZw= +sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= +sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= +sigs.k8s.io/structured-merge-diff/v4 v4.4.1 h1:150L+0vs/8DA78h1u02ooW1/fFq/Lwr+sGiqlzvrtq4= +sigs.k8s.io/structured-merge-diff/v4 v4.4.1/go.mod h1:N8hJocpFajUSSeSJ9bOZ77VzejKZaXsTtZo4/u7Io08= sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= diff --git a/informers/admissionregistration/v1alpha1/interface.go b/informers/admissionregistration/v1alpha1/interface.go index 310c64724..529ad5832 100644 --- a/informers/admissionregistration/v1alpha1/interface.go +++ b/informers/admissionregistration/v1alpha1/interface.go @@ -27,10 +27,6 @@ type ClusterInterface interface { ValidatingAdmissionPolicies() ValidatingAdmissionPolicyClusterInformer // ValidatingAdmissionPolicyBindings returns a ValidatingAdmissionPolicyBindingClusterInformer ValidatingAdmissionPolicyBindings() ValidatingAdmissionPolicyBindingClusterInformer - // MutatingAdmissionPolicies returns a MutatingAdmissionPolicyClusterInformer - MutatingAdmissionPolicies() MutatingAdmissionPolicyClusterInformer - // MutatingAdmissionPolicyBindings returns a MutatingAdmissionPolicyBindingClusterInformer - MutatingAdmissionPolicyBindings() MutatingAdmissionPolicyBindingClusterInformer } type version struct { @@ -52,13 +48,3 @@ func (v *version) ValidatingAdmissionPolicies() ValidatingAdmissionPolicyCluster func (v *version) ValidatingAdmissionPolicyBindings() ValidatingAdmissionPolicyBindingClusterInformer { return &validatingAdmissionPolicyBindingClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} } - -// MutatingAdmissionPolicies returns a MutatingAdmissionPolicyClusterInformer -func (v *version) MutatingAdmissionPolicies() MutatingAdmissionPolicyClusterInformer { - return &mutatingAdmissionPolicyClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} -} - -// MutatingAdmissionPolicyBindings returns a MutatingAdmissionPolicyBindingClusterInformer -func (v *version) MutatingAdmissionPolicyBindings() MutatingAdmissionPolicyBindingClusterInformer { - return &mutatingAdmissionPolicyBindingClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} -} diff --git a/informers/admissionregistration/v1alpha1/mutatingadmissionpolicy.go b/informers/admissionregistration/v1alpha1/mutatingadmissionpolicy.go deleted file mode 100644 index 8a5ad638b..000000000 --- a/informers/admissionregistration/v1alpha1/mutatingadmissionpolicy.go +++ /dev/null @@ -1,121 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1alpha1 - -import ( - "context" - "time" - - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - kcpinformers "github.com/kcp-dev/apimachinery/v2/third_party/informers" - "github.com/kcp-dev/logicalcluster/v3" - - admissionregistrationv1alpha1 "k8s.io/api/admissionregistration/v1alpha1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/watch" - upstreamadmissionregistrationv1alpha1informers "k8s.io/client-go/informers/admissionregistration/v1alpha1" - upstreamadmissionregistrationv1alpha1listers "k8s.io/client-go/listers/admissionregistration/v1alpha1" - "k8s.io/client-go/tools/cache" - - "github.com/kcp-dev/client-go/informers/internalinterfaces" - clientset "github.com/kcp-dev/client-go/kubernetes" - admissionregistrationv1alpha1listers "github.com/kcp-dev/client-go/listers/admissionregistration/v1alpha1" -) - -// MutatingAdmissionPolicyClusterInformer provides access to a shared informer and lister for -// MutatingAdmissionPolicies. -type MutatingAdmissionPolicyClusterInformer interface { - Cluster(logicalcluster.Name) upstreamadmissionregistrationv1alpha1informers.MutatingAdmissionPolicyInformer - Informer() kcpcache.ScopeableSharedIndexInformer - Lister() admissionregistrationv1alpha1listers.MutatingAdmissionPolicyClusterLister -} - -type mutatingAdmissionPolicyClusterInformer struct { - factory internalinterfaces.SharedInformerFactory - tweakListOptions internalinterfaces.TweakListOptionsFunc -} - -// NewMutatingAdmissionPolicyClusterInformer constructs a new informer for MutatingAdmissionPolicy type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewMutatingAdmissionPolicyClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredMutatingAdmissionPolicyClusterInformer(client, resyncPeriod, indexers, nil) -} - -// NewFilteredMutatingAdmissionPolicyClusterInformer constructs a new informer for MutatingAdmissionPolicy type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewFilteredMutatingAdmissionPolicyClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) kcpcache.ScopeableSharedIndexInformer { - return kcpinformers.NewSharedIndexInformer( - &cache.ListWatch{ - ListFunc: func(options metav1.ListOptions) (runtime.Object, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.AdmissionregistrationV1alpha1().MutatingAdmissionPolicies().List(context.TODO(), options) - }, - WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.AdmissionregistrationV1alpha1().MutatingAdmissionPolicies().Watch(context.TODO(), options) - }, - }, - &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}, - resyncPeriod, - indexers, - ) -} - -func (f *mutatingAdmissionPolicyClusterInformer) defaultInformer(client clientset.ClusterInterface, resyncPeriod time.Duration) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredMutatingAdmissionPolicyClusterInformer(client, resyncPeriod, cache.Indexers{ - kcpcache.ClusterIndexName: kcpcache.ClusterIndexFunc, - }, - f.tweakListOptions, - ) -} - -func (f *mutatingAdmissionPolicyClusterInformer) Informer() kcpcache.ScopeableSharedIndexInformer { - return f.factory.InformerFor(&admissionregistrationv1alpha1.MutatingAdmissionPolicy{}, f.defaultInformer) -} - -func (f *mutatingAdmissionPolicyClusterInformer) Lister() admissionregistrationv1alpha1listers.MutatingAdmissionPolicyClusterLister { - return admissionregistrationv1alpha1listers.NewMutatingAdmissionPolicyClusterLister(f.Informer().GetIndexer()) -} - -func (f *mutatingAdmissionPolicyClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamadmissionregistrationv1alpha1informers.MutatingAdmissionPolicyInformer { - return &mutatingAdmissionPolicyInformer{ - informer: f.Informer().Cluster(clusterName), - lister: f.Lister().Cluster(clusterName), - } -} - -type mutatingAdmissionPolicyInformer struct { - informer cache.SharedIndexInformer - lister upstreamadmissionregistrationv1alpha1listers.MutatingAdmissionPolicyLister -} - -func (f *mutatingAdmissionPolicyInformer) Informer() cache.SharedIndexInformer { - return f.informer -} - -func (f *mutatingAdmissionPolicyInformer) Lister() upstreamadmissionregistrationv1alpha1listers.MutatingAdmissionPolicyLister { - return f.lister -} diff --git a/informers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go b/informers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go deleted file mode 100644 index 403921714..000000000 --- a/informers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go +++ /dev/null @@ -1,121 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1alpha1 - -import ( - "context" - "time" - - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - kcpinformers "github.com/kcp-dev/apimachinery/v2/third_party/informers" - "github.com/kcp-dev/logicalcluster/v3" - - admissionregistrationv1alpha1 "k8s.io/api/admissionregistration/v1alpha1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/watch" - upstreamadmissionregistrationv1alpha1informers "k8s.io/client-go/informers/admissionregistration/v1alpha1" - upstreamadmissionregistrationv1alpha1listers "k8s.io/client-go/listers/admissionregistration/v1alpha1" - "k8s.io/client-go/tools/cache" - - "github.com/kcp-dev/client-go/informers/internalinterfaces" - clientset "github.com/kcp-dev/client-go/kubernetes" - admissionregistrationv1alpha1listers "github.com/kcp-dev/client-go/listers/admissionregistration/v1alpha1" -) - -// MutatingAdmissionPolicyBindingClusterInformer provides access to a shared informer and lister for -// MutatingAdmissionPolicyBindings. -type MutatingAdmissionPolicyBindingClusterInformer interface { - Cluster(logicalcluster.Name) upstreamadmissionregistrationv1alpha1informers.MutatingAdmissionPolicyBindingInformer - Informer() kcpcache.ScopeableSharedIndexInformer - Lister() admissionregistrationv1alpha1listers.MutatingAdmissionPolicyBindingClusterLister -} - -type mutatingAdmissionPolicyBindingClusterInformer struct { - factory internalinterfaces.SharedInformerFactory - tweakListOptions internalinterfaces.TweakListOptionsFunc -} - -// NewMutatingAdmissionPolicyBindingClusterInformer constructs a new informer for MutatingAdmissionPolicyBinding type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewMutatingAdmissionPolicyBindingClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredMutatingAdmissionPolicyBindingClusterInformer(client, resyncPeriod, indexers, nil) -} - -// NewFilteredMutatingAdmissionPolicyBindingClusterInformer constructs a new informer for MutatingAdmissionPolicyBinding type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewFilteredMutatingAdmissionPolicyBindingClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) kcpcache.ScopeableSharedIndexInformer { - return kcpinformers.NewSharedIndexInformer( - &cache.ListWatch{ - ListFunc: func(options metav1.ListOptions) (runtime.Object, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.AdmissionregistrationV1alpha1().MutatingAdmissionPolicyBindings().List(context.TODO(), options) - }, - WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.AdmissionregistrationV1alpha1().MutatingAdmissionPolicyBindings().Watch(context.TODO(), options) - }, - }, - &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}, - resyncPeriod, - indexers, - ) -} - -func (f *mutatingAdmissionPolicyBindingClusterInformer) defaultInformer(client clientset.ClusterInterface, resyncPeriod time.Duration) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredMutatingAdmissionPolicyBindingClusterInformer(client, resyncPeriod, cache.Indexers{ - kcpcache.ClusterIndexName: kcpcache.ClusterIndexFunc, - }, - f.tweakListOptions, - ) -} - -func (f *mutatingAdmissionPolicyBindingClusterInformer) Informer() kcpcache.ScopeableSharedIndexInformer { - return f.factory.InformerFor(&admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}, f.defaultInformer) -} - -func (f *mutatingAdmissionPolicyBindingClusterInformer) Lister() admissionregistrationv1alpha1listers.MutatingAdmissionPolicyBindingClusterLister { - return admissionregistrationv1alpha1listers.NewMutatingAdmissionPolicyBindingClusterLister(f.Informer().GetIndexer()) -} - -func (f *mutatingAdmissionPolicyBindingClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamadmissionregistrationv1alpha1informers.MutatingAdmissionPolicyBindingInformer { - return &mutatingAdmissionPolicyBindingInformer{ - informer: f.Informer().Cluster(clusterName), - lister: f.Lister().Cluster(clusterName), - } -} - -type mutatingAdmissionPolicyBindingInformer struct { - informer cache.SharedIndexInformer - lister upstreamadmissionregistrationv1alpha1listers.MutatingAdmissionPolicyBindingLister -} - -func (f *mutatingAdmissionPolicyBindingInformer) Informer() cache.SharedIndexInformer { - return f.informer -} - -func (f *mutatingAdmissionPolicyBindingInformer) Lister() upstreamadmissionregistrationv1alpha1listers.MutatingAdmissionPolicyBindingLister { - return f.lister -} diff --git a/informers/coordination/interface.go b/informers/coordination/interface.go index dabeca5f7..e1887eb39 100644 --- a/informers/coordination/interface.go +++ b/informers/coordination/interface.go @@ -20,7 +20,7 @@ package coordination import ( "github.com/kcp-dev/client-go/informers/coordination/v1" - "github.com/kcp-dev/client-go/informers/coordination/v1alpha2" + "github.com/kcp-dev/client-go/informers/coordination/v1alpha1" "github.com/kcp-dev/client-go/informers/coordination/v1beta1" "github.com/kcp-dev/client-go/informers/internalinterfaces" ) @@ -28,8 +28,8 @@ import ( type ClusterInterface interface { // V1 provides access to the shared informers in V1. V1() v1.ClusterInterface - // V1alpha2 provides access to the shared informers in V1alpha2. - V1alpha2() v1alpha2.ClusterInterface + // V1alpha1 provides access to the shared informers in V1alpha1. + V1alpha1() v1alpha1.ClusterInterface // V1beta1 provides access to the shared informers in V1beta1. V1beta1() v1beta1.ClusterInterface } @@ -49,9 +49,9 @@ func (g *group) V1() v1.ClusterInterface { return v1.New(g.factory, g.tweakListOptions) } -// V1alpha2 returns a new v1alpha2.ClusterInterface. -func (g *group) V1alpha2() v1alpha2.ClusterInterface { - return v1alpha2.New(g.factory, g.tweakListOptions) +// V1alpha1 returns a new v1alpha1.ClusterInterface. +func (g *group) V1alpha1() v1alpha1.ClusterInterface { + return v1alpha1.New(g.factory, g.tweakListOptions) } // V1beta1 returns a new v1beta1.ClusterInterface. diff --git a/informers/coordination/v1alpha2/interface.go b/informers/coordination/v1alpha1/interface.go similarity index 98% rename from informers/coordination/v1alpha2/interface.go rename to informers/coordination/v1alpha1/interface.go index ad5f0ecd4..3717f25e5 100644 --- a/informers/coordination/v1alpha2/interface.go +++ b/informers/coordination/v1alpha1/interface.go @@ -16,7 +16,7 @@ limitations under the License. // Code generated by kcp code-generator. DO NOT EDIT. -package v1alpha2 +package v1alpha1 import ( "github.com/kcp-dev/client-go/informers/internalinterfaces" diff --git a/informers/coordination/v1alpha2/leasecandidate.go b/informers/coordination/v1alpha1/leasecandidate.go similarity index 80% rename from informers/coordination/v1alpha2/leasecandidate.go rename to informers/coordination/v1alpha1/leasecandidate.go index 551b59aa7..62f009ea6 100644 --- a/informers/coordination/v1alpha2/leasecandidate.go +++ b/informers/coordination/v1alpha1/leasecandidate.go @@ -16,7 +16,7 @@ limitations under the License. // Code generated by kcp code-generator. DO NOT EDIT. -package v1alpha2 +package v1alpha1 import ( "context" @@ -26,25 +26,25 @@ import ( kcpinformers "github.com/kcp-dev/apimachinery/v2/third_party/informers" "github.com/kcp-dev/logicalcluster/v3" - coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/runtime" "k8s.io/apimachinery/pkg/watch" - upstreamcoordinationv1alpha2informers "k8s.io/client-go/informers/coordination/v1alpha2" - upstreamcoordinationv1alpha2listers "k8s.io/client-go/listers/coordination/v1alpha2" + upstreamcoordinationv1alpha1informers "k8s.io/client-go/informers/coordination/v1alpha1" + upstreamcoordinationv1alpha1listers "k8s.io/client-go/listers/coordination/v1alpha1" "k8s.io/client-go/tools/cache" "github.com/kcp-dev/client-go/informers/internalinterfaces" clientset "github.com/kcp-dev/client-go/kubernetes" - coordinationv1alpha2listers "github.com/kcp-dev/client-go/listers/coordination/v1alpha2" + coordinationv1alpha1listers "github.com/kcp-dev/client-go/listers/coordination/v1alpha1" ) // LeaseCandidateClusterInformer provides access to a shared informer and lister for // LeaseCandidates. type LeaseCandidateClusterInformer interface { - Cluster(logicalcluster.Name) upstreamcoordinationv1alpha2informers.LeaseCandidateInformer + Cluster(logicalcluster.Name) upstreamcoordinationv1alpha1informers.LeaseCandidateInformer Informer() kcpcache.ScopeableSharedIndexInformer - Lister() coordinationv1alpha2listers.LeaseCandidateClusterLister + Lister() coordinationv1alpha1listers.LeaseCandidateClusterLister } type leaseCandidateClusterInformer struct { @@ -69,16 +69,16 @@ func NewFilteredLeaseCandidateClusterInformer(client clientset.ClusterInterface, if tweakListOptions != nil { tweakListOptions(&options) } - return client.CoordinationV1alpha2().LeaseCandidates().List(context.TODO(), options) + return client.CoordinationV1alpha1().LeaseCandidates().List(context.TODO(), options) }, WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { if tweakListOptions != nil { tweakListOptions(&options) } - return client.CoordinationV1alpha2().LeaseCandidates().Watch(context.TODO(), options) + return client.CoordinationV1alpha1().LeaseCandidates().Watch(context.TODO(), options) }, }, - &coordinationv1alpha2.LeaseCandidate{}, + &coordinationv1alpha1.LeaseCandidate{}, resyncPeriod, indexers, ) @@ -93,14 +93,14 @@ func (f *leaseCandidateClusterInformer) defaultInformer(client clientset.Cluster } func (f *leaseCandidateClusterInformer) Informer() kcpcache.ScopeableSharedIndexInformer { - return f.factory.InformerFor(&coordinationv1alpha2.LeaseCandidate{}, f.defaultInformer) + return f.factory.InformerFor(&coordinationv1alpha1.LeaseCandidate{}, f.defaultInformer) } -func (f *leaseCandidateClusterInformer) Lister() coordinationv1alpha2listers.LeaseCandidateClusterLister { - return coordinationv1alpha2listers.NewLeaseCandidateClusterLister(f.Informer().GetIndexer()) +func (f *leaseCandidateClusterInformer) Lister() coordinationv1alpha1listers.LeaseCandidateClusterLister { + return coordinationv1alpha1listers.NewLeaseCandidateClusterLister(f.Informer().GetIndexer()) } -func (f *leaseCandidateClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamcoordinationv1alpha2informers.LeaseCandidateInformer { +func (f *leaseCandidateClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamcoordinationv1alpha1informers.LeaseCandidateInformer { return &leaseCandidateInformer{ informer: f.Informer().Cluster(clusterName), lister: f.Lister().Cluster(clusterName), @@ -109,13 +109,13 @@ func (f *leaseCandidateClusterInformer) Cluster(clusterName logicalcluster.Name) type leaseCandidateInformer struct { informer cache.SharedIndexInformer - lister upstreamcoordinationv1alpha2listers.LeaseCandidateLister + lister upstreamcoordinationv1alpha1listers.LeaseCandidateLister } func (f *leaseCandidateInformer) Informer() cache.SharedIndexInformer { return f.informer } -func (f *leaseCandidateInformer) Lister() upstreamcoordinationv1alpha2listers.LeaseCandidateLister { +func (f *leaseCandidateInformer) Lister() upstreamcoordinationv1alpha1listers.LeaseCandidateLister { return f.lister } diff --git a/informers/generic.go b/informers/generic.go index 3652a1b75..88879081e 100644 --- a/informers/generic.go +++ b/informers/generic.go @@ -41,7 +41,7 @@ import ( certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1" certificatesv1beta1 "k8s.io/api/certificates/v1beta1" coordinationv1 "k8s.io/api/coordination/v1" - coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1" coordinationv1beta1 "k8s.io/api/coordination/v1beta1" corev1 "k8s.io/api/core/v1" discoveryv1 "k8s.io/api/discovery/v1" @@ -65,7 +65,6 @@ import ( rbacv1alpha1 "k8s.io/api/rbac/v1alpha1" rbacv1beta1 "k8s.io/api/rbac/v1beta1" resourcev1alpha3 "k8s.io/api/resource/v1alpha3" - resourcev1beta1 "k8s.io/api/resource/v1beta1" schedulingv1 "k8s.io/api/scheduling/v1" schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1" schedulingv1beta1 "k8s.io/api/scheduling/v1beta1" @@ -140,10 +139,6 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1alpha1().ValidatingAdmissionPolicies().Informer()}, nil case admissionregistrationv1alpha1.SchemeGroupVersion.WithResource("validatingadmissionpolicybindings"): return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1alpha1().ValidatingAdmissionPolicyBindings().Informer()}, nil - case admissionregistrationv1alpha1.SchemeGroupVersion.WithResource("mutatingadmissionpolicies"): - return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1alpha1().MutatingAdmissionPolicies().Informer()}, nil - case admissionregistrationv1alpha1.SchemeGroupVersion.WithResource("mutatingadmissionpolicybindings"): - return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1alpha1().MutatingAdmissionPolicyBindings().Informer()}, nil // Group=admissionregistration.k8s.io, Version=V1beta1 case admissionregistrationv1beta1.SchemeGroupVersion.WithResource("validatingadmissionpolicies"): return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Admissionregistration().V1beta1().ValidatingAdmissionPolicies().Informer()}, nil @@ -214,9 +209,9 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource // Group=coordination.k8s.io, Version=V1 case coordinationv1.SchemeGroupVersion.WithResource("leases"): return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Coordination().V1().Leases().Informer()}, nil - // Group=coordination.k8s.io, Version=V1alpha2 - case coordinationv1alpha2.SchemeGroupVersion.WithResource("leasecandidates"): - return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Coordination().V1alpha2().LeaseCandidates().Informer()}, nil + // Group=coordination.k8s.io, Version=V1alpha1 + case coordinationv1alpha1.SchemeGroupVersion.WithResource("leasecandidates"): + return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Coordination().V1alpha1().LeaseCandidates().Informer()}, nil // Group=coordination.k8s.io, Version=V1beta1 case coordinationv1beta1.SchemeGroupVersion.WithResource("leases"): return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Coordination().V1beta1().Leases().Informer()}, nil @@ -367,19 +362,12 @@ func (f *sharedInformerFactory) ForResource(resource schema.GroupVersionResource return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1alpha3().ResourceSlices().Informer()}, nil case resourcev1alpha3.SchemeGroupVersion.WithResource("resourceclaims"): return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1alpha3().ResourceClaims().Informer()}, nil + case resourcev1alpha3.SchemeGroupVersion.WithResource("podschedulingcontexts"): + return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1alpha3().PodSchedulingContexts().Informer()}, nil case resourcev1alpha3.SchemeGroupVersion.WithResource("deviceclasses"): return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1alpha3().DeviceClasses().Informer()}, nil case resourcev1alpha3.SchemeGroupVersion.WithResource("resourceclaimtemplates"): return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1alpha3().ResourceClaimTemplates().Informer()}, nil - // Group=resource.k8s.io, Version=V1beta1 - case resourcev1beta1.SchemeGroupVersion.WithResource("resourceslices"): - return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta1().ResourceSlices().Informer()}, nil - case resourcev1beta1.SchemeGroupVersion.WithResource("resourceclaims"): - return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta1().ResourceClaims().Informer()}, nil - case resourcev1beta1.SchemeGroupVersion.WithResource("deviceclasses"): - return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta1().DeviceClasses().Informer()}, nil - case resourcev1beta1.SchemeGroupVersion.WithResource("resourceclaimtemplates"): - return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Resource().V1beta1().ResourceClaimTemplates().Informer()}, nil // Group=scheduling.k8s.io, Version=V1 case schedulingv1.SchemeGroupVersion.WithResource("priorityclasses"): return &genericClusterInformer{resource: resource.GroupResource(), informer: f.Scheduling().V1().PriorityClasses().Informer()}, nil diff --git a/informers/resource/interface.go b/informers/resource/interface.go index 758c184f4..34c92d07f 100644 --- a/informers/resource/interface.go +++ b/informers/resource/interface.go @@ -21,14 +21,11 @@ package resource import ( "github.com/kcp-dev/client-go/informers/internalinterfaces" "github.com/kcp-dev/client-go/informers/resource/v1alpha3" - "github.com/kcp-dev/client-go/informers/resource/v1beta1" ) type ClusterInterface interface { // V1alpha3 provides access to the shared informers in V1alpha3. V1alpha3() v1alpha3.ClusterInterface - // V1beta1 provides access to the shared informers in V1beta1. - V1beta1() v1beta1.ClusterInterface } type group struct { @@ -45,8 +42,3 @@ func New(f internalinterfaces.SharedInformerFactory, tweakListOptions internalin func (g *group) V1alpha3() v1alpha3.ClusterInterface { return v1alpha3.New(g.factory, g.tweakListOptions) } - -// V1beta1 returns a new v1beta1.ClusterInterface. -func (g *group) V1beta1() v1beta1.ClusterInterface { - return v1beta1.New(g.factory, g.tweakListOptions) -} diff --git a/informers/resource/v1alpha3/interface.go b/informers/resource/v1alpha3/interface.go index 8727a3efb..a89f0c1c4 100644 --- a/informers/resource/v1alpha3/interface.go +++ b/informers/resource/v1alpha3/interface.go @@ -27,6 +27,8 @@ type ClusterInterface interface { ResourceSlices() ResourceSliceClusterInformer // ResourceClaims returns a ResourceClaimClusterInformer ResourceClaims() ResourceClaimClusterInformer + // PodSchedulingContexts returns a PodSchedulingContextClusterInformer + PodSchedulingContexts() PodSchedulingContextClusterInformer // DeviceClasses returns a DeviceClassClusterInformer DeviceClasses() DeviceClassClusterInformer // ResourceClaimTemplates returns a ResourceClaimTemplateClusterInformer @@ -53,6 +55,11 @@ func (v *version) ResourceClaims() ResourceClaimClusterInformer { return &resourceClaimClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} } +// PodSchedulingContexts returns a PodSchedulingContextClusterInformer +func (v *version) PodSchedulingContexts() PodSchedulingContextClusterInformer { + return &podSchedulingContextClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} +} + // DeviceClasses returns a DeviceClassClusterInformer func (v *version) DeviceClasses() DeviceClassClusterInformer { return &deviceClassClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} diff --git a/informers/resource/v1alpha3/podschedulingcontext.go b/informers/resource/v1alpha3/podschedulingcontext.go new file mode 100644 index 000000000..9bfef28d4 --- /dev/null +++ b/informers/resource/v1alpha3/podschedulingcontext.go @@ -0,0 +1,121 @@ +/* +Copyright The KCP 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 kcp code-generator. DO NOT EDIT. + +package v1alpha3 + +import ( + "context" + "time" + + kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" + kcpinformers "github.com/kcp-dev/apimachinery/v2/third_party/informers" + "github.com/kcp-dev/logicalcluster/v3" + + resourcev1alpha3 "k8s.io/api/resource/v1alpha3" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/watch" + upstreamresourcev1alpha3informers "k8s.io/client-go/informers/resource/v1alpha3" + upstreamresourcev1alpha3listers "k8s.io/client-go/listers/resource/v1alpha3" + "k8s.io/client-go/tools/cache" + + "github.com/kcp-dev/client-go/informers/internalinterfaces" + clientset "github.com/kcp-dev/client-go/kubernetes" + resourcev1alpha3listers "github.com/kcp-dev/client-go/listers/resource/v1alpha3" +) + +// PodSchedulingContextClusterInformer provides access to a shared informer and lister for +// PodSchedulingContexts. +type PodSchedulingContextClusterInformer interface { + Cluster(logicalcluster.Name) upstreamresourcev1alpha3informers.PodSchedulingContextInformer + Informer() kcpcache.ScopeableSharedIndexInformer + Lister() resourcev1alpha3listers.PodSchedulingContextClusterLister +} + +type podSchedulingContextClusterInformer struct { + factory internalinterfaces.SharedInformerFactory + tweakListOptions internalinterfaces.TweakListOptionsFunc +} + +// NewPodSchedulingContextClusterInformer constructs a new informer for PodSchedulingContext type. +// Always prefer using an informer factory to get a shared informer instead of getting an independent +// one. This reduces memory footprint and number of connections to the server. +func NewPodSchedulingContextClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers) kcpcache.ScopeableSharedIndexInformer { + return NewFilteredPodSchedulingContextClusterInformer(client, resyncPeriod, indexers, nil) +} + +// NewFilteredPodSchedulingContextClusterInformer constructs a new informer for PodSchedulingContext type. +// Always prefer using an informer factory to get a shared informer instead of getting an independent +// one. This reduces memory footprint and number of connections to the server. +func NewFilteredPodSchedulingContextClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) kcpcache.ScopeableSharedIndexInformer { + return kcpinformers.NewSharedIndexInformer( + &cache.ListWatch{ + ListFunc: func(options metav1.ListOptions) (runtime.Object, error) { + if tweakListOptions != nil { + tweakListOptions(&options) + } + return client.ResourceV1alpha3().PodSchedulingContexts().List(context.TODO(), options) + }, + WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { + if tweakListOptions != nil { + tweakListOptions(&options) + } + return client.ResourceV1alpha3().PodSchedulingContexts().Watch(context.TODO(), options) + }, + }, + &resourcev1alpha3.PodSchedulingContext{}, + resyncPeriod, + indexers, + ) +} + +func (f *podSchedulingContextClusterInformer) defaultInformer(client clientset.ClusterInterface, resyncPeriod time.Duration) kcpcache.ScopeableSharedIndexInformer { + return NewFilteredPodSchedulingContextClusterInformer(client, resyncPeriod, cache.Indexers{ + kcpcache.ClusterIndexName: kcpcache.ClusterIndexFunc, + kcpcache.ClusterAndNamespaceIndexName: kcpcache.ClusterAndNamespaceIndexFunc}, + f.tweakListOptions, + ) +} + +func (f *podSchedulingContextClusterInformer) Informer() kcpcache.ScopeableSharedIndexInformer { + return f.factory.InformerFor(&resourcev1alpha3.PodSchedulingContext{}, f.defaultInformer) +} + +func (f *podSchedulingContextClusterInformer) Lister() resourcev1alpha3listers.PodSchedulingContextClusterLister { + return resourcev1alpha3listers.NewPodSchedulingContextClusterLister(f.Informer().GetIndexer()) +} + +func (f *podSchedulingContextClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamresourcev1alpha3informers.PodSchedulingContextInformer { + return &podSchedulingContextInformer{ + informer: f.Informer().Cluster(clusterName), + lister: f.Lister().Cluster(clusterName), + } +} + +type podSchedulingContextInformer struct { + informer cache.SharedIndexInformer + lister upstreamresourcev1alpha3listers.PodSchedulingContextLister +} + +func (f *podSchedulingContextInformer) Informer() cache.SharedIndexInformer { + return f.informer +} + +func (f *podSchedulingContextInformer) Lister() upstreamresourcev1alpha3listers.PodSchedulingContextLister { + return f.lister +} diff --git a/informers/resource/v1beta1/deviceclass.go b/informers/resource/v1beta1/deviceclass.go deleted file mode 100644 index 5a328522f..000000000 --- a/informers/resource/v1beta1/deviceclass.go +++ /dev/null @@ -1,121 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "context" - "time" - - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - kcpinformers "github.com/kcp-dev/apimachinery/v2/third_party/informers" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/watch" - upstreamresourcev1beta1informers "k8s.io/client-go/informers/resource/v1beta1" - upstreamresourcev1beta1listers "k8s.io/client-go/listers/resource/v1beta1" - "k8s.io/client-go/tools/cache" - - "github.com/kcp-dev/client-go/informers/internalinterfaces" - clientset "github.com/kcp-dev/client-go/kubernetes" - resourcev1beta1listers "github.com/kcp-dev/client-go/listers/resource/v1beta1" -) - -// DeviceClassClusterInformer provides access to a shared informer and lister for -// DeviceClasses. -type DeviceClassClusterInformer interface { - Cluster(logicalcluster.Name) upstreamresourcev1beta1informers.DeviceClassInformer - Informer() kcpcache.ScopeableSharedIndexInformer - Lister() resourcev1beta1listers.DeviceClassClusterLister -} - -type deviceClassClusterInformer struct { - factory internalinterfaces.SharedInformerFactory - tweakListOptions internalinterfaces.TweakListOptionsFunc -} - -// NewDeviceClassClusterInformer constructs a new informer for DeviceClass type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewDeviceClassClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredDeviceClassClusterInformer(client, resyncPeriod, indexers, nil) -} - -// NewFilteredDeviceClassClusterInformer constructs a new informer for DeviceClass type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewFilteredDeviceClassClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) kcpcache.ScopeableSharedIndexInformer { - return kcpinformers.NewSharedIndexInformer( - &cache.ListWatch{ - ListFunc: func(options metav1.ListOptions) (runtime.Object, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ResourceV1beta1().DeviceClasses().List(context.TODO(), options) - }, - WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ResourceV1beta1().DeviceClasses().Watch(context.TODO(), options) - }, - }, - &resourcev1beta1.DeviceClass{}, - resyncPeriod, - indexers, - ) -} - -func (f *deviceClassClusterInformer) defaultInformer(client clientset.ClusterInterface, resyncPeriod time.Duration) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredDeviceClassClusterInformer(client, resyncPeriod, cache.Indexers{ - kcpcache.ClusterIndexName: kcpcache.ClusterIndexFunc, - }, - f.tweakListOptions, - ) -} - -func (f *deviceClassClusterInformer) Informer() kcpcache.ScopeableSharedIndexInformer { - return f.factory.InformerFor(&resourcev1beta1.DeviceClass{}, f.defaultInformer) -} - -func (f *deviceClassClusterInformer) Lister() resourcev1beta1listers.DeviceClassClusterLister { - return resourcev1beta1listers.NewDeviceClassClusterLister(f.Informer().GetIndexer()) -} - -func (f *deviceClassClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamresourcev1beta1informers.DeviceClassInformer { - return &deviceClassInformer{ - informer: f.Informer().Cluster(clusterName), - lister: f.Lister().Cluster(clusterName), - } -} - -type deviceClassInformer struct { - informer cache.SharedIndexInformer - lister upstreamresourcev1beta1listers.DeviceClassLister -} - -func (f *deviceClassInformer) Informer() cache.SharedIndexInformer { - return f.informer -} - -func (f *deviceClassInformer) Lister() upstreamresourcev1beta1listers.DeviceClassLister { - return f.lister -} diff --git a/informers/resource/v1beta1/interface.go b/informers/resource/v1beta1/interface.go deleted file mode 100644 index e90d40d95..000000000 --- a/informers/resource/v1beta1/interface.go +++ /dev/null @@ -1,64 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "github.com/kcp-dev/client-go/informers/internalinterfaces" -) - -type ClusterInterface interface { - // ResourceSlices returns a ResourceSliceClusterInformer - ResourceSlices() ResourceSliceClusterInformer - // ResourceClaims returns a ResourceClaimClusterInformer - ResourceClaims() ResourceClaimClusterInformer - // DeviceClasses returns a DeviceClassClusterInformer - DeviceClasses() DeviceClassClusterInformer - // ResourceClaimTemplates returns a ResourceClaimTemplateClusterInformer - ResourceClaimTemplates() ResourceClaimTemplateClusterInformer -} - -type version struct { - factory internalinterfaces.SharedInformerFactory - tweakListOptions internalinterfaces.TweakListOptionsFunc -} - -// New returns a new ClusterInterface. -func New(f internalinterfaces.SharedInformerFactory, tweakListOptions internalinterfaces.TweakListOptionsFunc) ClusterInterface { - return &version{factory: f, tweakListOptions: tweakListOptions} -} - -// ResourceSlices returns a ResourceSliceClusterInformer -func (v *version) ResourceSlices() ResourceSliceClusterInformer { - return &resourceSliceClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} -} - -// ResourceClaims returns a ResourceClaimClusterInformer -func (v *version) ResourceClaims() ResourceClaimClusterInformer { - return &resourceClaimClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} -} - -// DeviceClasses returns a DeviceClassClusterInformer -func (v *version) DeviceClasses() DeviceClassClusterInformer { - return &deviceClassClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} -} - -// ResourceClaimTemplates returns a ResourceClaimTemplateClusterInformer -func (v *version) ResourceClaimTemplates() ResourceClaimTemplateClusterInformer { - return &resourceClaimTemplateClusterInformer{factory: v.factory, tweakListOptions: v.tweakListOptions} -} diff --git a/informers/resource/v1beta1/resourceclaim.go b/informers/resource/v1beta1/resourceclaim.go deleted file mode 100644 index b588d75dc..000000000 --- a/informers/resource/v1beta1/resourceclaim.go +++ /dev/null @@ -1,121 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "context" - "time" - - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - kcpinformers "github.com/kcp-dev/apimachinery/v2/third_party/informers" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/watch" - upstreamresourcev1beta1informers "k8s.io/client-go/informers/resource/v1beta1" - upstreamresourcev1beta1listers "k8s.io/client-go/listers/resource/v1beta1" - "k8s.io/client-go/tools/cache" - - "github.com/kcp-dev/client-go/informers/internalinterfaces" - clientset "github.com/kcp-dev/client-go/kubernetes" - resourcev1beta1listers "github.com/kcp-dev/client-go/listers/resource/v1beta1" -) - -// ResourceClaimClusterInformer provides access to a shared informer and lister for -// ResourceClaims. -type ResourceClaimClusterInformer interface { - Cluster(logicalcluster.Name) upstreamresourcev1beta1informers.ResourceClaimInformer - Informer() kcpcache.ScopeableSharedIndexInformer - Lister() resourcev1beta1listers.ResourceClaimClusterLister -} - -type resourceClaimClusterInformer struct { - factory internalinterfaces.SharedInformerFactory - tweakListOptions internalinterfaces.TweakListOptionsFunc -} - -// NewResourceClaimClusterInformer constructs a new informer for ResourceClaim type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewResourceClaimClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredResourceClaimClusterInformer(client, resyncPeriod, indexers, nil) -} - -// NewFilteredResourceClaimClusterInformer constructs a new informer for ResourceClaim type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewFilteredResourceClaimClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) kcpcache.ScopeableSharedIndexInformer { - return kcpinformers.NewSharedIndexInformer( - &cache.ListWatch{ - ListFunc: func(options metav1.ListOptions) (runtime.Object, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ResourceV1beta1().ResourceClaims().List(context.TODO(), options) - }, - WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ResourceV1beta1().ResourceClaims().Watch(context.TODO(), options) - }, - }, - &resourcev1beta1.ResourceClaim{}, - resyncPeriod, - indexers, - ) -} - -func (f *resourceClaimClusterInformer) defaultInformer(client clientset.ClusterInterface, resyncPeriod time.Duration) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredResourceClaimClusterInformer(client, resyncPeriod, cache.Indexers{ - kcpcache.ClusterIndexName: kcpcache.ClusterIndexFunc, - kcpcache.ClusterAndNamespaceIndexName: kcpcache.ClusterAndNamespaceIndexFunc}, - f.tweakListOptions, - ) -} - -func (f *resourceClaimClusterInformer) Informer() kcpcache.ScopeableSharedIndexInformer { - return f.factory.InformerFor(&resourcev1beta1.ResourceClaim{}, f.defaultInformer) -} - -func (f *resourceClaimClusterInformer) Lister() resourcev1beta1listers.ResourceClaimClusterLister { - return resourcev1beta1listers.NewResourceClaimClusterLister(f.Informer().GetIndexer()) -} - -func (f *resourceClaimClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamresourcev1beta1informers.ResourceClaimInformer { - return &resourceClaimInformer{ - informer: f.Informer().Cluster(clusterName), - lister: f.Lister().Cluster(clusterName), - } -} - -type resourceClaimInformer struct { - informer cache.SharedIndexInformer - lister upstreamresourcev1beta1listers.ResourceClaimLister -} - -func (f *resourceClaimInformer) Informer() cache.SharedIndexInformer { - return f.informer -} - -func (f *resourceClaimInformer) Lister() upstreamresourcev1beta1listers.ResourceClaimLister { - return f.lister -} diff --git a/informers/resource/v1beta1/resourceclaimtemplate.go b/informers/resource/v1beta1/resourceclaimtemplate.go deleted file mode 100644 index 6b1fd9661..000000000 --- a/informers/resource/v1beta1/resourceclaimtemplate.go +++ /dev/null @@ -1,121 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "context" - "time" - - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - kcpinformers "github.com/kcp-dev/apimachinery/v2/third_party/informers" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/watch" - upstreamresourcev1beta1informers "k8s.io/client-go/informers/resource/v1beta1" - upstreamresourcev1beta1listers "k8s.io/client-go/listers/resource/v1beta1" - "k8s.io/client-go/tools/cache" - - "github.com/kcp-dev/client-go/informers/internalinterfaces" - clientset "github.com/kcp-dev/client-go/kubernetes" - resourcev1beta1listers "github.com/kcp-dev/client-go/listers/resource/v1beta1" -) - -// ResourceClaimTemplateClusterInformer provides access to a shared informer and lister for -// ResourceClaimTemplates. -type ResourceClaimTemplateClusterInformer interface { - Cluster(logicalcluster.Name) upstreamresourcev1beta1informers.ResourceClaimTemplateInformer - Informer() kcpcache.ScopeableSharedIndexInformer - Lister() resourcev1beta1listers.ResourceClaimTemplateClusterLister -} - -type resourceClaimTemplateClusterInformer struct { - factory internalinterfaces.SharedInformerFactory - tweakListOptions internalinterfaces.TweakListOptionsFunc -} - -// NewResourceClaimTemplateClusterInformer constructs a new informer for ResourceClaimTemplate type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewResourceClaimTemplateClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredResourceClaimTemplateClusterInformer(client, resyncPeriod, indexers, nil) -} - -// NewFilteredResourceClaimTemplateClusterInformer constructs a new informer for ResourceClaimTemplate type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewFilteredResourceClaimTemplateClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) kcpcache.ScopeableSharedIndexInformer { - return kcpinformers.NewSharedIndexInformer( - &cache.ListWatch{ - ListFunc: func(options metav1.ListOptions) (runtime.Object, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ResourceV1beta1().ResourceClaimTemplates().List(context.TODO(), options) - }, - WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ResourceV1beta1().ResourceClaimTemplates().Watch(context.TODO(), options) - }, - }, - &resourcev1beta1.ResourceClaimTemplate{}, - resyncPeriod, - indexers, - ) -} - -func (f *resourceClaimTemplateClusterInformer) defaultInformer(client clientset.ClusterInterface, resyncPeriod time.Duration) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredResourceClaimTemplateClusterInformer(client, resyncPeriod, cache.Indexers{ - kcpcache.ClusterIndexName: kcpcache.ClusterIndexFunc, - kcpcache.ClusterAndNamespaceIndexName: kcpcache.ClusterAndNamespaceIndexFunc}, - f.tweakListOptions, - ) -} - -func (f *resourceClaimTemplateClusterInformer) Informer() kcpcache.ScopeableSharedIndexInformer { - return f.factory.InformerFor(&resourcev1beta1.ResourceClaimTemplate{}, f.defaultInformer) -} - -func (f *resourceClaimTemplateClusterInformer) Lister() resourcev1beta1listers.ResourceClaimTemplateClusterLister { - return resourcev1beta1listers.NewResourceClaimTemplateClusterLister(f.Informer().GetIndexer()) -} - -func (f *resourceClaimTemplateClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamresourcev1beta1informers.ResourceClaimTemplateInformer { - return &resourceClaimTemplateInformer{ - informer: f.Informer().Cluster(clusterName), - lister: f.Lister().Cluster(clusterName), - } -} - -type resourceClaimTemplateInformer struct { - informer cache.SharedIndexInformer - lister upstreamresourcev1beta1listers.ResourceClaimTemplateLister -} - -func (f *resourceClaimTemplateInformer) Informer() cache.SharedIndexInformer { - return f.informer -} - -func (f *resourceClaimTemplateInformer) Lister() upstreamresourcev1beta1listers.ResourceClaimTemplateLister { - return f.lister -} diff --git a/informers/resource/v1beta1/resourceslice.go b/informers/resource/v1beta1/resourceslice.go deleted file mode 100644 index 366f4b63a..000000000 --- a/informers/resource/v1beta1/resourceslice.go +++ /dev/null @@ -1,121 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "context" - "time" - - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - kcpinformers "github.com/kcp-dev/apimachinery/v2/third_party/informers" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/runtime" - "k8s.io/apimachinery/pkg/watch" - upstreamresourcev1beta1informers "k8s.io/client-go/informers/resource/v1beta1" - upstreamresourcev1beta1listers "k8s.io/client-go/listers/resource/v1beta1" - "k8s.io/client-go/tools/cache" - - "github.com/kcp-dev/client-go/informers/internalinterfaces" - clientset "github.com/kcp-dev/client-go/kubernetes" - resourcev1beta1listers "github.com/kcp-dev/client-go/listers/resource/v1beta1" -) - -// ResourceSliceClusterInformer provides access to a shared informer and lister for -// ResourceSlices. -type ResourceSliceClusterInformer interface { - Cluster(logicalcluster.Name) upstreamresourcev1beta1informers.ResourceSliceInformer - Informer() kcpcache.ScopeableSharedIndexInformer - Lister() resourcev1beta1listers.ResourceSliceClusterLister -} - -type resourceSliceClusterInformer struct { - factory internalinterfaces.SharedInformerFactory - tweakListOptions internalinterfaces.TweakListOptionsFunc -} - -// NewResourceSliceClusterInformer constructs a new informer for ResourceSlice type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewResourceSliceClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredResourceSliceClusterInformer(client, resyncPeriod, indexers, nil) -} - -// NewFilteredResourceSliceClusterInformer constructs a new informer for ResourceSlice type. -// Always prefer using an informer factory to get a shared informer instead of getting an independent -// one. This reduces memory footprint and number of connections to the server. -func NewFilteredResourceSliceClusterInformer(client clientset.ClusterInterface, resyncPeriod time.Duration, indexers cache.Indexers, tweakListOptions internalinterfaces.TweakListOptionsFunc) kcpcache.ScopeableSharedIndexInformer { - return kcpinformers.NewSharedIndexInformer( - &cache.ListWatch{ - ListFunc: func(options metav1.ListOptions) (runtime.Object, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ResourceV1beta1().ResourceSlices().List(context.TODO(), options) - }, - WatchFunc: func(options metav1.ListOptions) (watch.Interface, error) { - if tweakListOptions != nil { - tweakListOptions(&options) - } - return client.ResourceV1beta1().ResourceSlices().Watch(context.TODO(), options) - }, - }, - &resourcev1beta1.ResourceSlice{}, - resyncPeriod, - indexers, - ) -} - -func (f *resourceSliceClusterInformer) defaultInformer(client clientset.ClusterInterface, resyncPeriod time.Duration) kcpcache.ScopeableSharedIndexInformer { - return NewFilteredResourceSliceClusterInformer(client, resyncPeriod, cache.Indexers{ - kcpcache.ClusterIndexName: kcpcache.ClusterIndexFunc, - }, - f.tweakListOptions, - ) -} - -func (f *resourceSliceClusterInformer) Informer() kcpcache.ScopeableSharedIndexInformer { - return f.factory.InformerFor(&resourcev1beta1.ResourceSlice{}, f.defaultInformer) -} - -func (f *resourceSliceClusterInformer) Lister() resourcev1beta1listers.ResourceSliceClusterLister { - return resourcev1beta1listers.NewResourceSliceClusterLister(f.Informer().GetIndexer()) -} - -func (f *resourceSliceClusterInformer) Cluster(clusterName logicalcluster.Name) upstreamresourcev1beta1informers.ResourceSliceInformer { - return &resourceSliceInformer{ - informer: f.Informer().Cluster(clusterName), - lister: f.Lister().Cluster(clusterName), - } -} - -type resourceSliceInformer struct { - informer cache.SharedIndexInformer - lister upstreamresourcev1beta1listers.ResourceSliceLister -} - -func (f *resourceSliceInformer) Informer() cache.SharedIndexInformer { - return f.informer -} - -func (f *resourceSliceInformer) Lister() upstreamresourcev1beta1listers.ResourceSliceLister { - return f.lister -} diff --git a/kubernetes/clientset.go b/kubernetes/clientset.go index 8a4ff969a..41d40e646 100644 --- a/kubernetes/clientset.go +++ b/kubernetes/clientset.go @@ -52,7 +52,7 @@ import ( certificatesv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/certificates/v1alpha1" certificatesv1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/certificates/v1beta1" coordinationv1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1" - coordinationv1alpha2 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha2" + coordinationv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha1" coordinationv1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1beta1" corev1 "github.com/kcp-dev/client-go/kubernetes/typed/core/v1" discoveryv1 "github.com/kcp-dev/client-go/kubernetes/typed/discovery/v1" @@ -76,7 +76,6 @@ import ( rbacv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/rbac/v1alpha1" rbacv1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/rbac/v1beta1" resourcev1alpha3 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1alpha3" - resourcev1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1beta1" schedulingv1 "github.com/kcp-dev/client-go/kubernetes/typed/scheduling/v1" schedulingv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/scheduling/v1alpha1" schedulingv1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/scheduling/v1beta1" @@ -110,7 +109,7 @@ type ClusterInterface interface { CertificatesV1alpha1() certificatesv1alpha1.CertificatesV1alpha1ClusterInterface CertificatesV1beta1() certificatesv1beta1.CertificatesV1beta1ClusterInterface CoordinationV1() coordinationv1.CoordinationV1ClusterInterface - CoordinationV1alpha2() coordinationv1alpha2.CoordinationV1alpha2ClusterInterface + CoordinationV1alpha1() coordinationv1alpha1.CoordinationV1alpha1ClusterInterface CoordinationV1beta1() coordinationv1beta1.CoordinationV1beta1ClusterInterface CoreV1() corev1.CoreV1ClusterInterface DiscoveryV1() discoveryv1.DiscoveryV1ClusterInterface @@ -135,7 +134,6 @@ type ClusterInterface interface { RbacV1alpha1() rbacv1alpha1.RbacV1alpha1ClusterInterface RbacV1beta1() rbacv1beta1.RbacV1beta1ClusterInterface ResourceV1alpha3() resourcev1alpha3.ResourceV1alpha3ClusterInterface - ResourceV1beta1() resourcev1beta1.ResourceV1beta1ClusterInterface SchedulingV1() schedulingv1.SchedulingV1ClusterInterface SchedulingV1alpha1() schedulingv1alpha1.SchedulingV1alpha1ClusterInterface SchedulingV1beta1() schedulingv1beta1.SchedulingV1beta1ClusterInterface @@ -170,7 +168,7 @@ type ClusterClientset struct { certificatesV1alpha1 *certificatesv1alpha1.CertificatesV1alpha1ClusterClient certificatesV1beta1 *certificatesv1beta1.CertificatesV1beta1ClusterClient coordinationV1 *coordinationv1.CoordinationV1ClusterClient - coordinationV1alpha2 *coordinationv1alpha2.CoordinationV1alpha2ClusterClient + coordinationV1alpha1 *coordinationv1alpha1.CoordinationV1alpha1ClusterClient coordinationV1beta1 *coordinationv1beta1.CoordinationV1beta1ClusterClient coreV1 *corev1.CoreV1ClusterClient discoveryV1 *discoveryv1.DiscoveryV1ClusterClient @@ -195,7 +193,6 @@ type ClusterClientset struct { rbacV1alpha1 *rbacv1alpha1.RbacV1alpha1ClusterClient rbacV1beta1 *rbacv1beta1.RbacV1beta1ClusterClient resourceV1alpha3 *resourcev1alpha3.ResourceV1alpha3ClusterClient - resourceV1beta1 *resourcev1beta1.ResourceV1beta1ClusterClient schedulingV1 *schedulingv1.SchedulingV1ClusterClient schedulingV1alpha1 *schedulingv1alpha1.SchedulingV1alpha1ClusterClient schedulingV1beta1 *schedulingv1beta1.SchedulingV1beta1ClusterClient @@ -318,9 +315,9 @@ func (c *ClusterClientset) CoordinationV1() coordinationv1.CoordinationV1Cluster return c.coordinationV1 } -// CoordinationV1alpha2 retrieves the CoordinationV1alpha2ClusterClient. -func (c *ClusterClientset) CoordinationV1alpha2() coordinationv1alpha2.CoordinationV1alpha2ClusterInterface { - return c.coordinationV1alpha2 +// CoordinationV1alpha1 retrieves the CoordinationV1alpha1ClusterClient. +func (c *ClusterClientset) CoordinationV1alpha1() coordinationv1alpha1.CoordinationV1alpha1ClusterInterface { + return c.coordinationV1alpha1 } // CoordinationV1beta1 retrieves the CoordinationV1beta1ClusterClient. @@ -443,11 +440,6 @@ func (c *ClusterClientset) ResourceV1alpha3() resourcev1alpha3.ResourceV1alpha3C return c.resourceV1alpha3 } -// ResourceV1beta1 retrieves the ResourceV1beta1ClusterClient. -func (c *ClusterClientset) ResourceV1beta1() resourcev1beta1.ResourceV1beta1ClusterInterface { - return c.resourceV1beta1 -} - // SchedulingV1 retrieves the SchedulingV1ClusterClient. func (c *ClusterClientset) SchedulingV1() schedulingv1.SchedulingV1ClusterInterface { return c.schedulingV1 @@ -619,7 +611,7 @@ func NewForConfigAndClient(c *rest.Config, httpClient *http.Client) (*ClusterCli if err != nil { return nil, err } - cs.coordinationV1alpha2, err = coordinationv1alpha2.NewForConfigAndClient(&configShallowCopy, httpClient) + cs.coordinationV1alpha1, err = coordinationv1alpha1.NewForConfigAndClient(&configShallowCopy, httpClient) if err != nil { return nil, err } @@ -719,10 +711,6 @@ func NewForConfigAndClient(c *rest.Config, httpClient *http.Client) (*ClusterCli if err != nil { return nil, err } - cs.resourceV1beta1, err = resourcev1beta1.NewForConfigAndClient(&configShallowCopy, httpClient) - if err != nil { - return nil, err - } cs.schedulingV1, err = schedulingv1.NewForConfigAndClient(&configShallowCopy, httpClient) if err != nil { return nil, err diff --git a/kubernetes/fake/clientset.go b/kubernetes/fake/clientset.go index a1cd48f9d..b27af904b 100644 --- a/kubernetes/fake/clientset.go +++ b/kubernetes/fake/clientset.go @@ -47,7 +47,7 @@ import ( certificatesv1alpha1 "k8s.io/client-go/kubernetes/typed/certificates/v1alpha1" certificatesv1beta1 "k8s.io/client-go/kubernetes/typed/certificates/v1beta1" coordinationv1 "k8s.io/client-go/kubernetes/typed/coordination/v1" - coordinationv1alpha2 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1" coordinationv1beta1 "k8s.io/client-go/kubernetes/typed/coordination/v1beta1" corev1 "k8s.io/client-go/kubernetes/typed/core/v1" discoveryv1 "k8s.io/client-go/kubernetes/typed/discovery/v1" @@ -71,7 +71,6 @@ import ( rbacv1alpha1 "k8s.io/client-go/kubernetes/typed/rbac/v1alpha1" rbacv1beta1 "k8s.io/client-go/kubernetes/typed/rbac/v1beta1" resourcev1alpha3 "k8s.io/client-go/kubernetes/typed/resource/v1alpha3" - resourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1" schedulingv1 "k8s.io/client-go/kubernetes/typed/scheduling/v1" schedulingv1alpha1 "k8s.io/client-go/kubernetes/typed/scheduling/v1alpha1" schedulingv1beta1 "k8s.io/client-go/kubernetes/typed/scheduling/v1beta1" @@ -125,8 +124,8 @@ import ( fakecertificatesv1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/certificates/v1beta1/fake" kcpcoordinationv1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1" fakecoordinationv1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1/fake" - kcpcoordinationv1alpha2 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha2" - fakecoordinationv1alpha2 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha2/fake" + kcpcoordinationv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha1" + fakecoordinationv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha1/fake" kcpcoordinationv1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1beta1" fakecoordinationv1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1beta1/fake" kcpcorev1 "github.com/kcp-dev/client-go/kubernetes/typed/core/v1" @@ -173,8 +172,6 @@ import ( fakerbacv1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/rbac/v1beta1/fake" kcpresourcev1alpha3 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1alpha3" fakeresourcev1alpha3 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1alpha3/fake" - kcpresourcev1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1beta1" - fakeresourcev1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1beta1/fake" kcpschedulingv1 "github.com/kcp-dev/client-go/kubernetes/typed/scheduling/v1" fakeschedulingv1 "github.com/kcp-dev/client-go/kubernetes/typed/scheduling/v1/fake" kcpschedulingv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/scheduling/v1alpha1" @@ -332,9 +329,9 @@ func (c *ClusterClientset) CoordinationV1() kcpcoordinationv1.CoordinationV1Clus return &fakecoordinationv1.CoordinationV1ClusterClient{Fake: c.Fake} } -// CoordinationV1alpha2 retrieves the CoordinationV1alpha2ClusterClient. -func (c *ClusterClientset) CoordinationV1alpha2() kcpcoordinationv1alpha2.CoordinationV1alpha2ClusterInterface { - return &fakecoordinationv1alpha2.CoordinationV1alpha2ClusterClient{Fake: c.Fake} +// CoordinationV1alpha1 retrieves the CoordinationV1alpha1ClusterClient. +func (c *ClusterClientset) CoordinationV1alpha1() kcpcoordinationv1alpha1.CoordinationV1alpha1ClusterInterface { + return &fakecoordinationv1alpha1.CoordinationV1alpha1ClusterClient{Fake: c.Fake} } // CoordinationV1beta1 retrieves the CoordinationV1beta1ClusterClient. @@ -457,11 +454,6 @@ func (c *ClusterClientset) ResourceV1alpha3() kcpresourcev1alpha3.ResourceV1alph return &fakeresourcev1alpha3.ResourceV1alpha3ClusterClient{Fake: c.Fake} } -// ResourceV1beta1 retrieves the ResourceV1beta1ClusterClient. -func (c *ClusterClientset) ResourceV1beta1() kcpresourcev1beta1.ResourceV1beta1ClusterInterface { - return &fakeresourcev1beta1.ResourceV1beta1ClusterClient{Fake: c.Fake} -} - // SchedulingV1 retrieves the SchedulingV1ClusterClient. func (c *ClusterClientset) SchedulingV1() kcpschedulingv1.SchedulingV1ClusterInterface { return &fakeschedulingv1.SchedulingV1ClusterClient{Fake: c.Fake} @@ -634,9 +626,9 @@ func (c *Clientset) CoordinationV1() coordinationv1.CoordinationV1Interface { return &fakecoordinationv1.CoordinationV1Client{Fake: c.Fake, ClusterPath: c.clusterPath} } -// CoordinationV1alpha2 retrieves the CoordinationV1alpha2Client. -func (c *Clientset) CoordinationV1alpha2() coordinationv1alpha2.CoordinationV1alpha2Interface { - return &fakecoordinationv1alpha2.CoordinationV1alpha2Client{Fake: c.Fake, ClusterPath: c.clusterPath} +// CoordinationV1alpha1 retrieves the CoordinationV1alpha1Client. +func (c *Clientset) CoordinationV1alpha1() coordinationv1alpha1.CoordinationV1alpha1Interface { + return &fakecoordinationv1alpha1.CoordinationV1alpha1Client{Fake: c.Fake, ClusterPath: c.clusterPath} } // CoordinationV1beta1 retrieves the CoordinationV1beta1Client. @@ -759,11 +751,6 @@ func (c *Clientset) ResourceV1alpha3() resourcev1alpha3.ResourceV1alpha3Interfac return &fakeresourcev1alpha3.ResourceV1alpha3Client{Fake: c.Fake, ClusterPath: c.clusterPath} } -// ResourceV1beta1 retrieves the ResourceV1beta1Client. -func (c *Clientset) ResourceV1beta1() resourcev1beta1.ResourceV1beta1Interface { - return &fakeresourcev1beta1.ResourceV1beta1Client{Fake: c.Fake, ClusterPath: c.clusterPath} -} - // SchedulingV1 retrieves the SchedulingV1Client. func (c *Clientset) SchedulingV1() schedulingv1.SchedulingV1Interface { return &fakeschedulingv1.SchedulingV1Client{Fake: c.Fake, ClusterPath: c.clusterPath} diff --git a/kubernetes/scheme/register.go b/kubernetes/scheme/register.go index c5a45e766..58f3c9f1f 100644 --- a/kubernetes/scheme/register.go +++ b/kubernetes/scheme/register.go @@ -41,7 +41,7 @@ import ( certificatesv1alpha1 "k8s.io/api/certificates/v1alpha1" certificatesv1beta1 "k8s.io/api/certificates/v1beta1" coordinationv1 "k8s.io/api/coordination/v1" - coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1" coordinationv1beta1 "k8s.io/api/coordination/v1beta1" corev1 "k8s.io/api/core/v1" discoveryv1 "k8s.io/api/discovery/v1" @@ -65,7 +65,6 @@ import ( rbacv1alpha1 "k8s.io/api/rbac/v1alpha1" rbacv1beta1 "k8s.io/api/rbac/v1beta1" resourcev1alpha3 "k8s.io/api/resource/v1alpha3" - resourcev1beta1 "k8s.io/api/resource/v1beta1" schedulingv1 "k8s.io/api/scheduling/v1" schedulingv1alpha1 "k8s.io/api/scheduling/v1alpha1" schedulingv1beta1 "k8s.io/api/scheduling/v1beta1" @@ -105,7 +104,7 @@ var localSchemeBuilder = runtime.SchemeBuilder{ certificatesv1alpha1.AddToScheme, certificatesv1beta1.AddToScheme, coordinationv1.AddToScheme, - coordinationv1alpha2.AddToScheme, + coordinationv1alpha1.AddToScheme, coordinationv1beta1.AddToScheme, corev1.AddToScheme, discoveryv1.AddToScheme, @@ -130,7 +129,6 @@ var localSchemeBuilder = runtime.SchemeBuilder{ rbacv1alpha1.AddToScheme, rbacv1beta1.AddToScheme, resourcev1alpha3.AddToScheme, - resourcev1beta1.AddToScheme, schedulingv1.AddToScheme, schedulingv1alpha1.AddToScheme, schedulingv1beta1.AddToScheme, diff --git a/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go b/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go index 7ce577d36..4ab479af9 100644 --- a/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go +++ b/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go @@ -32,8 +32,6 @@ type AdmissionregistrationV1alpha1ClusterInterface interface { AdmissionregistrationV1alpha1ClusterScoper ValidatingAdmissionPoliciesClusterGetter ValidatingAdmissionPolicyBindingsClusterGetter - MutatingAdmissionPoliciesClusterGetter - MutatingAdmissionPolicyBindingsClusterGetter } type AdmissionregistrationV1alpha1ClusterScoper interface { @@ -59,14 +57,6 @@ func (c *AdmissionregistrationV1alpha1ClusterClient) ValidatingAdmissionPolicyBi return &validatingAdmissionPolicyBindingsClusterInterface{clientCache: c.clientCache} } -func (c *AdmissionregistrationV1alpha1ClusterClient) MutatingAdmissionPolicies() MutatingAdmissionPolicyClusterInterface { - return &mutatingAdmissionPoliciesClusterInterface{clientCache: c.clientCache} -} - -func (c *AdmissionregistrationV1alpha1ClusterClient) MutatingAdmissionPolicyBindings() MutatingAdmissionPolicyBindingClusterInterface { - return &mutatingAdmissionPolicyBindingsClusterInterface{clientCache: c.clientCache} -} - // NewForConfig creates a new AdmissionregistrationV1alpha1ClusterClient for the given config. // NewForConfig is equivalent to NewForConfigAndClient(c, httpClient), // where httpClient was generated with rest.HTTPClientFor(c). diff --git a/kubernetes/typed/admissionregistration/v1alpha1/fake/admissionregistration_client.go b/kubernetes/typed/admissionregistration/v1alpha1/fake/admissionregistration_client.go index 2c9919fe1..5be180322 100644 --- a/kubernetes/typed/admissionregistration/v1alpha1/fake/admissionregistration_client.go +++ b/kubernetes/typed/admissionregistration/v1alpha1/fake/admissionregistration_client.go @@ -49,14 +49,6 @@ func (c *AdmissionregistrationV1alpha1ClusterClient) ValidatingAdmissionPolicyBi return &validatingAdmissionPolicyBindingsClusterClient{Fake: c.Fake} } -func (c *AdmissionregistrationV1alpha1ClusterClient) MutatingAdmissionPolicies() kcpadmissionregistrationv1alpha1.MutatingAdmissionPolicyClusterInterface { - return &mutatingAdmissionPoliciesClusterClient{Fake: c.Fake} -} - -func (c *AdmissionregistrationV1alpha1ClusterClient) MutatingAdmissionPolicyBindings() kcpadmissionregistrationv1alpha1.MutatingAdmissionPolicyBindingClusterInterface { - return &mutatingAdmissionPolicyBindingsClusterClient{Fake: c.Fake} -} - var _ admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface = (*AdmissionregistrationV1alpha1Client)(nil) type AdmissionregistrationV1alpha1Client struct { @@ -76,11 +68,3 @@ func (c *AdmissionregistrationV1alpha1Client) ValidatingAdmissionPolicies() admi func (c *AdmissionregistrationV1alpha1Client) ValidatingAdmissionPolicyBindings() admissionregistrationv1alpha1.ValidatingAdmissionPolicyBindingInterface { return &validatingAdmissionPolicyBindingsClient{Fake: c.Fake, ClusterPath: c.ClusterPath} } - -func (c *AdmissionregistrationV1alpha1Client) MutatingAdmissionPolicies() admissionregistrationv1alpha1.MutatingAdmissionPolicyInterface { - return &mutatingAdmissionPoliciesClient{Fake: c.Fake, ClusterPath: c.ClusterPath} -} - -func (c *AdmissionregistrationV1alpha1Client) MutatingAdmissionPolicyBindings() admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingInterface { - return &mutatingAdmissionPolicyBindingsClient{Fake: c.Fake, ClusterPath: c.ClusterPath} -} diff --git a/kubernetes/typed/admissionregistration/v1alpha1/fake/mutatingadmissionpolicy.go b/kubernetes/typed/admissionregistration/v1alpha1/fake/mutatingadmissionpolicy.go deleted file mode 100644 index 97546e9f4..000000000 --- a/kubernetes/typed/admissionregistration/v1alpha1/fake/mutatingadmissionpolicy.go +++ /dev/null @@ -1,199 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package fake - -import ( - "context" - "encoding/json" - "fmt" - - "github.com/kcp-dev/logicalcluster/v3" - - admissionregistrationv1alpha1 "k8s.io/api/admissionregistration/v1alpha1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/labels" - "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/apimachinery/pkg/types" - "k8s.io/apimachinery/pkg/watch" - applyconfigurationsadmissionregistrationv1alpha1 "k8s.io/client-go/applyconfigurations/admissionregistration/v1alpha1" - admissionregistrationv1alpha1client "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1" - "k8s.io/client-go/testing" - - kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" -) - -var mutatingAdmissionPoliciesResource = schema.GroupVersionResource{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Resource: "mutatingadmissionpolicies"} -var mutatingAdmissionPoliciesKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "MutatingAdmissionPolicy"} - -type mutatingAdmissionPoliciesClusterClient struct { - *kcptesting.Fake -} - -// Cluster scopes the client down to a particular cluster. -func (c *mutatingAdmissionPoliciesClusterClient) Cluster(clusterPath logicalcluster.Path) admissionregistrationv1alpha1client.MutatingAdmissionPolicyInterface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return &mutatingAdmissionPoliciesClient{Fake: c.Fake, ClusterPath: clusterPath} -} - -// List takes label and field selectors, and returns the list of MutatingAdmissionPolicies that match those selectors across all clusters. -func (c *mutatingAdmissionPoliciesClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootListAction(mutatingAdmissionPoliciesResource, mutatingAdmissionPoliciesKind, logicalcluster.Wildcard, opts), &admissionregistrationv1alpha1.MutatingAdmissionPolicyList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &admissionregistrationv1alpha1.MutatingAdmissionPolicyList{ListMeta: obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyList).ListMeta} - for _, item := range obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -// Watch returns a watch.Interface that watches the requested MutatingAdmissionPolicies across all clusters. -func (c *mutatingAdmissionPoliciesClusterClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewRootWatchAction(mutatingAdmissionPoliciesResource, logicalcluster.Wildcard, opts)) -} - -type mutatingAdmissionPoliciesClient struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path -} - -func (c *mutatingAdmissionPoliciesClient) Create(ctx context.Context, mutatingAdmissionPolicy *admissionregistrationv1alpha1.MutatingAdmissionPolicy, opts metav1.CreateOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicy, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootCreateAction(mutatingAdmissionPoliciesResource, c.ClusterPath, mutatingAdmissionPolicy), &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy), err -} - -func (c *mutatingAdmissionPoliciesClient) Update(ctx context.Context, mutatingAdmissionPolicy *admissionregistrationv1alpha1.MutatingAdmissionPolicy, opts metav1.UpdateOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicy, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootUpdateAction(mutatingAdmissionPoliciesResource, c.ClusterPath, mutatingAdmissionPolicy), &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy), err -} - -func (c *mutatingAdmissionPoliciesClient) UpdateStatus(ctx context.Context, mutatingAdmissionPolicy *admissionregistrationv1alpha1.MutatingAdmissionPolicy, opts metav1.UpdateOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicy, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootUpdateSubresourceAction(mutatingAdmissionPoliciesResource, c.ClusterPath, "status", mutatingAdmissionPolicy), &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy), err -} - -func (c *mutatingAdmissionPoliciesClient) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { - _, err := c.Fake.Invokes(kcptesting.NewRootDeleteActionWithOptions(mutatingAdmissionPoliciesResource, c.ClusterPath, name, opts), &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}) - return err -} - -func (c *mutatingAdmissionPoliciesClient) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { - action := kcptesting.NewRootDeleteCollectionAction(mutatingAdmissionPoliciesResource, c.ClusterPath, listOpts) - - _, err := c.Fake.Invokes(action, &admissionregistrationv1alpha1.MutatingAdmissionPolicyList{}) - return err -} - -func (c *mutatingAdmissionPoliciesClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicy, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootGetAction(mutatingAdmissionPoliciesResource, c.ClusterPath, name), &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy), err -} - -// List takes label and field selectors, and returns the list of MutatingAdmissionPolicies that match those selectors. -func (c *mutatingAdmissionPoliciesClient) List(ctx context.Context, opts metav1.ListOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootListAction(mutatingAdmissionPoliciesResource, mutatingAdmissionPoliciesKind, c.ClusterPath, opts), &admissionregistrationv1alpha1.MutatingAdmissionPolicyList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &admissionregistrationv1alpha1.MutatingAdmissionPolicyList{ListMeta: obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyList).ListMeta} - for _, item := range obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -func (c *mutatingAdmissionPoliciesClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewRootWatchAction(mutatingAdmissionPoliciesResource, c.ClusterPath, opts)) -} - -func (c *mutatingAdmissionPoliciesClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*admissionregistrationv1alpha1.MutatingAdmissionPolicy, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(mutatingAdmissionPoliciesResource, c.ClusterPath, name, pt, data, subresources...), &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy), err -} - -func (c *mutatingAdmissionPoliciesClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationsadmissionregistrationv1alpha1.MutatingAdmissionPolicyApplyConfiguration, opts metav1.ApplyOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicy, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(mutatingAdmissionPoliciesResource, c.ClusterPath, *name, types.ApplyPatchType, data), &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy), err -} - -func (c *mutatingAdmissionPoliciesClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationsadmissionregistrationv1alpha1.MutatingAdmissionPolicyApplyConfiguration, opts metav1.ApplyOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicy, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(mutatingAdmissionPoliciesResource, c.ClusterPath, *name, types.ApplyPatchType, data, "status"), &admissionregistrationv1alpha1.MutatingAdmissionPolicy{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy), err -} diff --git a/kubernetes/typed/admissionregistration/v1alpha1/fake/mutatingadmissionpolicybinding.go b/kubernetes/typed/admissionregistration/v1alpha1/fake/mutatingadmissionpolicybinding.go deleted file mode 100644 index 06a51b03b..000000000 --- a/kubernetes/typed/admissionregistration/v1alpha1/fake/mutatingadmissionpolicybinding.go +++ /dev/null @@ -1,199 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package fake - -import ( - "context" - "encoding/json" - "fmt" - - "github.com/kcp-dev/logicalcluster/v3" - - admissionregistrationv1alpha1 "k8s.io/api/admissionregistration/v1alpha1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/labels" - "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/apimachinery/pkg/types" - "k8s.io/apimachinery/pkg/watch" - applyconfigurationsadmissionregistrationv1alpha1 "k8s.io/client-go/applyconfigurations/admissionregistration/v1alpha1" - admissionregistrationv1alpha1client "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1" - "k8s.io/client-go/testing" - - kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" -) - -var mutatingAdmissionPolicyBindingsResource = schema.GroupVersionResource{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Resource: "mutatingadmissionpolicybindings"} -var mutatingAdmissionPolicyBindingsKind = schema.GroupVersionKind{Group: "admissionregistration.k8s.io", Version: "v1alpha1", Kind: "MutatingAdmissionPolicyBinding"} - -type mutatingAdmissionPolicyBindingsClusterClient struct { - *kcptesting.Fake -} - -// Cluster scopes the client down to a particular cluster. -func (c *mutatingAdmissionPolicyBindingsClusterClient) Cluster(clusterPath logicalcluster.Path) admissionregistrationv1alpha1client.MutatingAdmissionPolicyBindingInterface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return &mutatingAdmissionPolicyBindingsClient{Fake: c.Fake, ClusterPath: clusterPath} -} - -// List takes label and field selectors, and returns the list of MutatingAdmissionPolicyBindings that match those selectors across all clusters. -func (c *mutatingAdmissionPolicyBindingsClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootListAction(mutatingAdmissionPolicyBindingsResource, mutatingAdmissionPolicyBindingsKind, logicalcluster.Wildcard, opts), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList{ListMeta: obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList).ListMeta} - for _, item := range obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -// Watch returns a watch.Interface that watches the requested MutatingAdmissionPolicyBindings across all clusters. -func (c *mutatingAdmissionPolicyBindingsClusterClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewRootWatchAction(mutatingAdmissionPolicyBindingsResource, logicalcluster.Wildcard, opts)) -} - -type mutatingAdmissionPolicyBindingsClient struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path -} - -func (c *mutatingAdmissionPolicyBindingsClient) Create(ctx context.Context, mutatingAdmissionPolicyBinding *admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, opts metav1.CreateOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootCreateAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, mutatingAdmissionPolicyBinding), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding), err -} - -func (c *mutatingAdmissionPolicyBindingsClient) Update(ctx context.Context, mutatingAdmissionPolicyBinding *admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, opts metav1.UpdateOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootUpdateAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, mutatingAdmissionPolicyBinding), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding), err -} - -func (c *mutatingAdmissionPolicyBindingsClient) UpdateStatus(ctx context.Context, mutatingAdmissionPolicyBinding *admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, opts metav1.UpdateOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootUpdateSubresourceAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, "status", mutatingAdmissionPolicyBinding), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding), err -} - -func (c *mutatingAdmissionPolicyBindingsClient) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { - _, err := c.Fake.Invokes(kcptesting.NewRootDeleteActionWithOptions(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, name, opts), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}) - return err -} - -func (c *mutatingAdmissionPolicyBindingsClient) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { - action := kcptesting.NewRootDeleteCollectionAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, listOpts) - - _, err := c.Fake.Invokes(action, &admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList{}) - return err -} - -func (c *mutatingAdmissionPolicyBindingsClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootGetAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, name), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding), err -} - -// List takes label and field selectors, and returns the list of MutatingAdmissionPolicyBindings that match those selectors. -func (c *mutatingAdmissionPolicyBindingsClient) List(ctx context.Context, opts metav1.ListOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootListAction(mutatingAdmissionPolicyBindingsResource, mutatingAdmissionPolicyBindingsKind, c.ClusterPath, opts), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList{ListMeta: obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList).ListMeta} - for _, item := range obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -func (c *mutatingAdmissionPolicyBindingsClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewRootWatchAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, opts)) -} - -func (c *mutatingAdmissionPolicyBindingsClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, name, pt, data, subresources...), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding), err -} - -func (c *mutatingAdmissionPolicyBindingsClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationsadmissionregistrationv1alpha1.MutatingAdmissionPolicyBindingApplyConfiguration, opts metav1.ApplyOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, *name, types.ApplyPatchType, data), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding), err -} - -func (c *mutatingAdmissionPolicyBindingsClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationsadmissionregistrationv1alpha1.MutatingAdmissionPolicyBindingApplyConfiguration, opts metav1.ApplyOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(mutatingAdmissionPolicyBindingsResource, c.ClusterPath, *name, types.ApplyPatchType, data, "status"), &admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding{}) - if obj == nil { - return nil, err - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding), err -} diff --git a/kubernetes/typed/admissionregistration/v1alpha1/mutatingadmissionpolicy.go b/kubernetes/typed/admissionregistration/v1alpha1/mutatingadmissionpolicy.go deleted file mode 100644 index e1a3144c4..000000000 --- a/kubernetes/typed/admissionregistration/v1alpha1/mutatingadmissionpolicy.go +++ /dev/null @@ -1,68 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1alpha1 - -import ( - "context" - - kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" - "github.com/kcp-dev/logicalcluster/v3" - - admissionregistrationv1alpha1 "k8s.io/api/admissionregistration/v1alpha1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/watch" - admissionregistrationv1alpha1client "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1" -) - -// MutatingAdmissionPoliciesClusterGetter has a method to return a MutatingAdmissionPolicyClusterInterface. -// A group's cluster client should implement this interface. -type MutatingAdmissionPoliciesClusterGetter interface { - MutatingAdmissionPolicies() MutatingAdmissionPolicyClusterInterface -} - -// MutatingAdmissionPolicyClusterInterface can operate on MutatingAdmissionPolicies across all clusters, -// or scope down to one cluster and return a admissionregistrationv1alpha1client.MutatingAdmissionPolicyInterface. -type MutatingAdmissionPolicyClusterInterface interface { - Cluster(logicalcluster.Path) admissionregistrationv1alpha1client.MutatingAdmissionPolicyInterface - List(ctx context.Context, opts metav1.ListOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyList, error) - Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) -} - -type mutatingAdmissionPoliciesClusterInterface struct { - clientCache kcpclient.Cache[*admissionregistrationv1alpha1client.AdmissionregistrationV1alpha1Client] -} - -// Cluster scopes the client down to a particular cluster. -func (c *mutatingAdmissionPoliciesClusterInterface) Cluster(clusterPath logicalcluster.Path) admissionregistrationv1alpha1client.MutatingAdmissionPolicyInterface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return c.clientCache.ClusterOrDie(clusterPath).MutatingAdmissionPolicies() -} - -// List returns the entire collection of all MutatingAdmissionPolicies across all clusters. -func (c *mutatingAdmissionPoliciesClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyList, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).MutatingAdmissionPolicies().List(ctx, opts) -} - -// Watch begins to watch all MutatingAdmissionPolicies across all clusters. -func (c *mutatingAdmissionPoliciesClusterInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).MutatingAdmissionPolicies().Watch(ctx, opts) -} diff --git a/kubernetes/typed/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go b/kubernetes/typed/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go deleted file mode 100644 index 407551647..000000000 --- a/kubernetes/typed/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go +++ /dev/null @@ -1,68 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1alpha1 - -import ( - "context" - - kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" - "github.com/kcp-dev/logicalcluster/v3" - - admissionregistrationv1alpha1 "k8s.io/api/admissionregistration/v1alpha1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/watch" - admissionregistrationv1alpha1client "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1" -) - -// MutatingAdmissionPolicyBindingsClusterGetter has a method to return a MutatingAdmissionPolicyBindingClusterInterface. -// A group's cluster client should implement this interface. -type MutatingAdmissionPolicyBindingsClusterGetter interface { - MutatingAdmissionPolicyBindings() MutatingAdmissionPolicyBindingClusterInterface -} - -// MutatingAdmissionPolicyBindingClusterInterface can operate on MutatingAdmissionPolicyBindings across all clusters, -// or scope down to one cluster and return a admissionregistrationv1alpha1client.MutatingAdmissionPolicyBindingInterface. -type MutatingAdmissionPolicyBindingClusterInterface interface { - Cluster(logicalcluster.Path) admissionregistrationv1alpha1client.MutatingAdmissionPolicyBindingInterface - List(ctx context.Context, opts metav1.ListOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList, error) - Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) -} - -type mutatingAdmissionPolicyBindingsClusterInterface struct { - clientCache kcpclient.Cache[*admissionregistrationv1alpha1client.AdmissionregistrationV1alpha1Client] -} - -// Cluster scopes the client down to a particular cluster. -func (c *mutatingAdmissionPolicyBindingsClusterInterface) Cluster(clusterPath logicalcluster.Path) admissionregistrationv1alpha1client.MutatingAdmissionPolicyBindingInterface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return c.clientCache.ClusterOrDie(clusterPath).MutatingAdmissionPolicyBindings() -} - -// List returns the entire collection of all MutatingAdmissionPolicyBindings across all clusters. -func (c *mutatingAdmissionPolicyBindingsClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBindingList, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).MutatingAdmissionPolicyBindings().List(ctx, opts) -} - -// Watch begins to watch all MutatingAdmissionPolicyBindings across all clusters. -func (c *mutatingAdmissionPolicyBindingsClusterInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).MutatingAdmissionPolicyBindings().Watch(ctx, opts) -} diff --git a/kubernetes/typed/coordination/v1alpha2/coordination_client.go b/kubernetes/typed/coordination/v1alpha1/coordination_client.go similarity index 62% rename from kubernetes/typed/coordination/v1alpha2/coordination_client.go rename to kubernetes/typed/coordination/v1alpha1/coordination_client.go index 94d5b6dda..557bb262f 100644 --- a/kubernetes/typed/coordination/v1alpha2/coordination_client.go +++ b/kubernetes/typed/coordination/v1alpha1/coordination_client.go @@ -16,7 +16,7 @@ limitations under the License. // Code generated by kcp code-generator. DO NOT EDIT. -package v1alpha2 +package v1alpha1 import ( "net/http" @@ -24,38 +24,38 @@ import ( kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" "github.com/kcp-dev/logicalcluster/v3" - coordinationv1alpha2 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1" "k8s.io/client-go/rest" ) -type CoordinationV1alpha2ClusterInterface interface { - CoordinationV1alpha2ClusterScoper +type CoordinationV1alpha1ClusterInterface interface { + CoordinationV1alpha1ClusterScoper LeaseCandidatesClusterGetter } -type CoordinationV1alpha2ClusterScoper interface { - Cluster(logicalcluster.Path) coordinationv1alpha2.CoordinationV1alpha2Interface +type CoordinationV1alpha1ClusterScoper interface { + Cluster(logicalcluster.Path) coordinationv1alpha1.CoordinationV1alpha1Interface } -type CoordinationV1alpha2ClusterClient struct { - clientCache kcpclient.Cache[*coordinationv1alpha2.CoordinationV1alpha2Client] +type CoordinationV1alpha1ClusterClient struct { + clientCache kcpclient.Cache[*coordinationv1alpha1.CoordinationV1alpha1Client] } -func (c *CoordinationV1alpha2ClusterClient) Cluster(clusterPath logicalcluster.Path) coordinationv1alpha2.CoordinationV1alpha2Interface { +func (c *CoordinationV1alpha1ClusterClient) Cluster(clusterPath logicalcluster.Path) coordinationv1alpha1.CoordinationV1alpha1Interface { if clusterPath == logicalcluster.Wildcard { panic("A specific cluster must be provided when scoping, not the wildcard.") } return c.clientCache.ClusterOrDie(clusterPath) } -func (c *CoordinationV1alpha2ClusterClient) LeaseCandidates() LeaseCandidateClusterInterface { +func (c *CoordinationV1alpha1ClusterClient) LeaseCandidates() LeaseCandidateClusterInterface { return &leaseCandidatesClusterInterface{clientCache: c.clientCache} } -// NewForConfig creates a new CoordinationV1alpha2ClusterClient for the given config. +// NewForConfig creates a new CoordinationV1alpha1ClusterClient for the given config. // NewForConfig is equivalent to NewForConfigAndClient(c, httpClient), // where httpClient was generated with rest.HTTPClientFor(c). -func NewForConfig(c *rest.Config) (*CoordinationV1alpha2ClusterClient, error) { +func NewForConfig(c *rest.Config) (*CoordinationV1alpha1ClusterClient, error) { client, err := rest.HTTPClientFor(c) if err != nil { return nil, err @@ -63,21 +63,21 @@ func NewForConfig(c *rest.Config) (*CoordinationV1alpha2ClusterClient, error) { return NewForConfigAndClient(c, client) } -// NewForConfigAndClient creates a new CoordinationV1alpha2ClusterClient for the given config and http client. +// NewForConfigAndClient creates a new CoordinationV1alpha1ClusterClient for the given config and http client. // Note the http client provided takes precedence over the configured transport values. -func NewForConfigAndClient(c *rest.Config, h *http.Client) (*CoordinationV1alpha2ClusterClient, error) { - cache := kcpclient.NewCache(c, h, &kcpclient.Constructor[*coordinationv1alpha2.CoordinationV1alpha2Client]{ - NewForConfigAndClient: coordinationv1alpha2.NewForConfigAndClient, +func NewForConfigAndClient(c *rest.Config, h *http.Client) (*CoordinationV1alpha1ClusterClient, error) { + cache := kcpclient.NewCache(c, h, &kcpclient.Constructor[*coordinationv1alpha1.CoordinationV1alpha1Client]{ + NewForConfigAndClient: coordinationv1alpha1.NewForConfigAndClient, }) if _, err := cache.Cluster(logicalcluster.Name("root").Path()); err != nil { return nil, err } - return &CoordinationV1alpha2ClusterClient{clientCache: cache}, nil + return &CoordinationV1alpha1ClusterClient{clientCache: cache}, nil } -// NewForConfigOrDie creates a new CoordinationV1alpha2ClusterClient for the given config and +// NewForConfigOrDie creates a new CoordinationV1alpha1ClusterClient for the given config and // panics if there is an error in the config. -func NewForConfigOrDie(c *rest.Config) *CoordinationV1alpha2ClusterClient { +func NewForConfigOrDie(c *rest.Config) *CoordinationV1alpha1ClusterClient { client, err := NewForConfig(c) if err != nil { panic(err) diff --git a/kubernetes/typed/coordination/v1alpha2/fake/coordination_client.go b/kubernetes/typed/coordination/v1alpha1/fake/coordination_client.go similarity index 55% rename from kubernetes/typed/coordination/v1alpha2/fake/coordination_client.go rename to kubernetes/typed/coordination/v1alpha1/fake/coordination_client.go index 851bbb35c..60e785dac 100644 --- a/kubernetes/typed/coordination/v1alpha2/fake/coordination_client.go +++ b/kubernetes/typed/coordination/v1alpha1/fake/coordination_client.go @@ -21,42 +21,42 @@ package fake import ( "github.com/kcp-dev/logicalcluster/v3" - coordinationv1alpha2 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1" "k8s.io/client-go/rest" - kcpcoordinationv1alpha2 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha2" + kcpcoordinationv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha1" kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" ) -var _ kcpcoordinationv1alpha2.CoordinationV1alpha2ClusterInterface = (*CoordinationV1alpha2ClusterClient)(nil) +var _ kcpcoordinationv1alpha1.CoordinationV1alpha1ClusterInterface = (*CoordinationV1alpha1ClusterClient)(nil) -type CoordinationV1alpha2ClusterClient struct { +type CoordinationV1alpha1ClusterClient struct { *kcptesting.Fake } -func (c *CoordinationV1alpha2ClusterClient) Cluster(clusterPath logicalcluster.Path) coordinationv1alpha2.CoordinationV1alpha2Interface { +func (c *CoordinationV1alpha1ClusterClient) Cluster(clusterPath logicalcluster.Path) coordinationv1alpha1.CoordinationV1alpha1Interface { if clusterPath == logicalcluster.Wildcard { panic("A specific cluster must be provided when scoping, not the wildcard.") } - return &CoordinationV1alpha2Client{Fake: c.Fake, ClusterPath: clusterPath} + return &CoordinationV1alpha1Client{Fake: c.Fake, ClusterPath: clusterPath} } -func (c *CoordinationV1alpha2ClusterClient) LeaseCandidates() kcpcoordinationv1alpha2.LeaseCandidateClusterInterface { +func (c *CoordinationV1alpha1ClusterClient) LeaseCandidates() kcpcoordinationv1alpha1.LeaseCandidateClusterInterface { return &leaseCandidatesClusterClient{Fake: c.Fake} } -var _ coordinationv1alpha2.CoordinationV1alpha2Interface = (*CoordinationV1alpha2Client)(nil) +var _ coordinationv1alpha1.CoordinationV1alpha1Interface = (*CoordinationV1alpha1Client)(nil) -type CoordinationV1alpha2Client struct { +type CoordinationV1alpha1Client struct { *kcptesting.Fake ClusterPath logicalcluster.Path } -func (c *CoordinationV1alpha2Client) RESTClient() rest.Interface { +func (c *CoordinationV1alpha1Client) RESTClient() rest.Interface { var ret *rest.RESTClient return ret } -func (c *CoordinationV1alpha2Client) LeaseCandidates(namespace string) coordinationv1alpha2.LeaseCandidateInterface { +func (c *CoordinationV1alpha1Client) LeaseCandidates(namespace string) coordinationv1alpha1.LeaseCandidateInterface { return &leaseCandidatesClient{Fake: c.Fake, ClusterPath: c.ClusterPath, Namespace: namespace} } diff --git a/kubernetes/typed/coordination/v1alpha2/fake/leasecandidate.go b/kubernetes/typed/coordination/v1alpha1/fake/leasecandidate.go similarity index 71% rename from kubernetes/typed/coordination/v1alpha2/fake/leasecandidate.go rename to kubernetes/typed/coordination/v1alpha1/fake/leasecandidate.go index 6c0a495aa..57b0e1a8f 100644 --- a/kubernetes/typed/coordination/v1alpha2/fake/leasecandidate.go +++ b/kubernetes/typed/coordination/v1alpha1/fake/leasecandidate.go @@ -25,29 +25,29 @@ import ( "github.com/kcp-dev/logicalcluster/v3" - coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/labels" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/apimachinery/pkg/types" "k8s.io/apimachinery/pkg/watch" - applyconfigurationscoordinationv1alpha2 "k8s.io/client-go/applyconfigurations/coordination/v1alpha2" - coordinationv1alpha2client "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2" + applyconfigurationscoordinationv1alpha1 "k8s.io/client-go/applyconfigurations/coordination/v1alpha1" + coordinationv1alpha1client "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1" "k8s.io/client-go/testing" - kcpcoordinationv1alpha2 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha2" + kcpcoordinationv1alpha1 "github.com/kcp-dev/client-go/kubernetes/typed/coordination/v1alpha1" kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" ) -var leaseCandidatesResource = schema.GroupVersionResource{Group: "coordination.k8s.io", Version: "v1alpha2", Resource: "leasecandidates"} -var leaseCandidatesKind = schema.GroupVersionKind{Group: "coordination.k8s.io", Version: "v1alpha2", Kind: "LeaseCandidate"} +var leaseCandidatesResource = schema.GroupVersionResource{Group: "coordination.k8s.io", Version: "v1alpha1", Resource: "leasecandidates"} +var leaseCandidatesKind = schema.GroupVersionKind{Group: "coordination.k8s.io", Version: "v1alpha1", Kind: "LeaseCandidate"} type leaseCandidatesClusterClient struct { *kcptesting.Fake } // Cluster scopes the client down to a particular cluster. -func (c *leaseCandidatesClusterClient) Cluster(clusterPath logicalcluster.Path) kcpcoordinationv1alpha2.LeaseCandidatesNamespacer { +func (c *leaseCandidatesClusterClient) Cluster(clusterPath logicalcluster.Path) kcpcoordinationv1alpha1.LeaseCandidatesNamespacer { if clusterPath == logicalcluster.Wildcard { panic("A specific cluster must be provided when scoping, not the wildcard.") } @@ -56,8 +56,8 @@ func (c *leaseCandidatesClusterClient) Cluster(clusterPath logicalcluster.Path) } // List takes label and field selectors, and returns the list of LeaseCandidates that match those selectors across all clusters. -func (c *leaseCandidatesClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*coordinationv1alpha2.LeaseCandidateList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewListAction(leaseCandidatesResource, leaseCandidatesKind, logicalcluster.Wildcard, metav1.NamespaceAll, opts), &coordinationv1alpha2.LeaseCandidateList{}) +func (c *leaseCandidatesClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*coordinationv1alpha1.LeaseCandidateList, error) { + obj, err := c.Fake.Invokes(kcptesting.NewListAction(leaseCandidatesResource, leaseCandidatesKind, logicalcluster.Wildcard, metav1.NamespaceAll, opts), &coordinationv1alpha1.LeaseCandidateList{}) if obj == nil { return nil, err } @@ -66,8 +66,8 @@ func (c *leaseCandidatesClusterClient) List(ctx context.Context, opts metav1.Lis if label == nil { label = labels.Everything() } - list := &coordinationv1alpha2.LeaseCandidateList{ListMeta: obj.(*coordinationv1alpha2.LeaseCandidateList).ListMeta} - for _, item := range obj.(*coordinationv1alpha2.LeaseCandidateList).Items { + list := &coordinationv1alpha1.LeaseCandidateList{ListMeta: obj.(*coordinationv1alpha1.LeaseCandidateList).ListMeta} + for _, item := range obj.(*coordinationv1alpha1.LeaseCandidateList).Items { if label.Matches(labels.Set(item.Labels)) { list.Items = append(list.Items, item) } @@ -85,7 +85,7 @@ type leaseCandidatesNamespacer struct { ClusterPath logicalcluster.Path } -func (n *leaseCandidatesNamespacer) Namespace(namespace string) coordinationv1alpha2client.LeaseCandidateInterface { +func (n *leaseCandidatesNamespacer) Namespace(namespace string) coordinationv1alpha1client.LeaseCandidateInterface { return &leaseCandidatesClient{Fake: n.Fake, ClusterPath: n.ClusterPath, Namespace: namespace} } @@ -95,53 +95,53 @@ type leaseCandidatesClient struct { Namespace string } -func (c *leaseCandidatesClient) Create(ctx context.Context, leaseCandidate *coordinationv1alpha2.LeaseCandidate, opts metav1.CreateOptions) (*coordinationv1alpha2.LeaseCandidate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewCreateAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, leaseCandidate), &coordinationv1alpha2.LeaseCandidate{}) +func (c *leaseCandidatesClient) Create(ctx context.Context, leaseCandidate *coordinationv1alpha1.LeaseCandidate, opts metav1.CreateOptions) (*coordinationv1alpha1.LeaseCandidate, error) { + obj, err := c.Fake.Invokes(kcptesting.NewCreateAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, leaseCandidate), &coordinationv1alpha1.LeaseCandidate{}) if obj == nil { return nil, err } - return obj.(*coordinationv1alpha2.LeaseCandidate), err + return obj.(*coordinationv1alpha1.LeaseCandidate), err } -func (c *leaseCandidatesClient) Update(ctx context.Context, leaseCandidate *coordinationv1alpha2.LeaseCandidate, opts metav1.UpdateOptions) (*coordinationv1alpha2.LeaseCandidate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewUpdateAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, leaseCandidate), &coordinationv1alpha2.LeaseCandidate{}) +func (c *leaseCandidatesClient) Update(ctx context.Context, leaseCandidate *coordinationv1alpha1.LeaseCandidate, opts metav1.UpdateOptions) (*coordinationv1alpha1.LeaseCandidate, error) { + obj, err := c.Fake.Invokes(kcptesting.NewUpdateAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, leaseCandidate), &coordinationv1alpha1.LeaseCandidate{}) if obj == nil { return nil, err } - return obj.(*coordinationv1alpha2.LeaseCandidate), err + return obj.(*coordinationv1alpha1.LeaseCandidate), err } -func (c *leaseCandidatesClient) UpdateStatus(ctx context.Context, leaseCandidate *coordinationv1alpha2.LeaseCandidate, opts metav1.UpdateOptions) (*coordinationv1alpha2.LeaseCandidate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewUpdateSubresourceAction(leaseCandidatesResource, c.ClusterPath, "status", c.Namespace, leaseCandidate), &coordinationv1alpha2.LeaseCandidate{}) +func (c *leaseCandidatesClient) UpdateStatus(ctx context.Context, leaseCandidate *coordinationv1alpha1.LeaseCandidate, opts metav1.UpdateOptions) (*coordinationv1alpha1.LeaseCandidate, error) { + obj, err := c.Fake.Invokes(kcptesting.NewUpdateSubresourceAction(leaseCandidatesResource, c.ClusterPath, "status", c.Namespace, leaseCandidate), &coordinationv1alpha1.LeaseCandidate{}) if obj == nil { return nil, err } - return obj.(*coordinationv1alpha2.LeaseCandidate), err + return obj.(*coordinationv1alpha1.LeaseCandidate), err } func (c *leaseCandidatesClient) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { - _, err := c.Fake.Invokes(kcptesting.NewDeleteActionWithOptions(leaseCandidatesResource, c.ClusterPath, c.Namespace, name, opts), &coordinationv1alpha2.LeaseCandidate{}) + _, err := c.Fake.Invokes(kcptesting.NewDeleteActionWithOptions(leaseCandidatesResource, c.ClusterPath, c.Namespace, name, opts), &coordinationv1alpha1.LeaseCandidate{}) return err } func (c *leaseCandidatesClient) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { action := kcptesting.NewDeleteCollectionAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, listOpts) - _, err := c.Fake.Invokes(action, &coordinationv1alpha2.LeaseCandidateList{}) + _, err := c.Fake.Invokes(action, &coordinationv1alpha1.LeaseCandidateList{}) return err } -func (c *leaseCandidatesClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*coordinationv1alpha2.LeaseCandidate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewGetAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, name), &coordinationv1alpha2.LeaseCandidate{}) +func (c *leaseCandidatesClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*coordinationv1alpha1.LeaseCandidate, error) { + obj, err := c.Fake.Invokes(kcptesting.NewGetAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, name), &coordinationv1alpha1.LeaseCandidate{}) if obj == nil { return nil, err } - return obj.(*coordinationv1alpha2.LeaseCandidate), err + return obj.(*coordinationv1alpha1.LeaseCandidate), err } // List takes label and field selectors, and returns the list of LeaseCandidates that match those selectors. -func (c *leaseCandidatesClient) List(ctx context.Context, opts metav1.ListOptions) (*coordinationv1alpha2.LeaseCandidateList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewListAction(leaseCandidatesResource, leaseCandidatesKind, c.ClusterPath, c.Namespace, opts), &coordinationv1alpha2.LeaseCandidateList{}) +func (c *leaseCandidatesClient) List(ctx context.Context, opts metav1.ListOptions) (*coordinationv1alpha1.LeaseCandidateList, error) { + obj, err := c.Fake.Invokes(kcptesting.NewListAction(leaseCandidatesResource, leaseCandidatesKind, c.ClusterPath, c.Namespace, opts), &coordinationv1alpha1.LeaseCandidateList{}) if obj == nil { return nil, err } @@ -150,8 +150,8 @@ func (c *leaseCandidatesClient) List(ctx context.Context, opts metav1.ListOption if label == nil { label = labels.Everything() } - list := &coordinationv1alpha2.LeaseCandidateList{ListMeta: obj.(*coordinationv1alpha2.LeaseCandidateList).ListMeta} - for _, item := range obj.(*coordinationv1alpha2.LeaseCandidateList).Items { + list := &coordinationv1alpha1.LeaseCandidateList{ListMeta: obj.(*coordinationv1alpha1.LeaseCandidateList).ListMeta} + for _, item := range obj.(*coordinationv1alpha1.LeaseCandidateList).Items { if label.Matches(labels.Set(item.Labels)) { list.Items = append(list.Items, item) } @@ -163,15 +163,15 @@ func (c *leaseCandidatesClient) Watch(ctx context.Context, opts metav1.ListOptio return c.Fake.InvokesWatch(kcptesting.NewWatchAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, opts)) } -func (c *leaseCandidatesClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*coordinationv1alpha2.LeaseCandidate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, name, pt, data, subresources...), &coordinationv1alpha2.LeaseCandidate{}) +func (c *leaseCandidatesClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*coordinationv1alpha1.LeaseCandidate, error) { + obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, name, pt, data, subresources...), &coordinationv1alpha1.LeaseCandidate{}) if obj == nil { return nil, err } - return obj.(*coordinationv1alpha2.LeaseCandidate), err + return obj.(*coordinationv1alpha1.LeaseCandidate), err } -func (c *leaseCandidatesClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationscoordinationv1alpha2.LeaseCandidateApplyConfiguration, opts metav1.ApplyOptions) (*coordinationv1alpha2.LeaseCandidate, error) { +func (c *leaseCandidatesClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationscoordinationv1alpha1.LeaseCandidateApplyConfiguration, opts metav1.ApplyOptions) (*coordinationv1alpha1.LeaseCandidate, error) { if applyConfiguration == nil { return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") } @@ -183,14 +183,14 @@ func (c *leaseCandidatesClient) Apply(ctx context.Context, applyConfiguration *a if name == nil { return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") } - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data), &coordinationv1alpha2.LeaseCandidate{}) + obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data), &coordinationv1alpha1.LeaseCandidate{}) if obj == nil { return nil, err } - return obj.(*coordinationv1alpha2.LeaseCandidate), err + return obj.(*coordinationv1alpha1.LeaseCandidate), err } -func (c *leaseCandidatesClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationscoordinationv1alpha2.LeaseCandidateApplyConfiguration, opts metav1.ApplyOptions) (*coordinationv1alpha2.LeaseCandidate, error) { +func (c *leaseCandidatesClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationscoordinationv1alpha1.LeaseCandidateApplyConfiguration, opts metav1.ApplyOptions) (*coordinationv1alpha1.LeaseCandidate, error) { if applyConfiguration == nil { return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") } @@ -202,9 +202,9 @@ func (c *leaseCandidatesClient) ApplyStatus(ctx context.Context, applyConfigurat if name == nil { return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") } - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data, "status"), &coordinationv1alpha2.LeaseCandidate{}) + obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(leaseCandidatesResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data, "status"), &coordinationv1alpha1.LeaseCandidate{}) if obj == nil { return nil, err } - return obj.(*coordinationv1alpha2.LeaseCandidate), err + return obj.(*coordinationv1alpha1.LeaseCandidate), err } diff --git a/kubernetes/typed/coordination/v1alpha2/leasecandidate.go b/kubernetes/typed/coordination/v1alpha1/leasecandidate.go similarity index 82% rename from kubernetes/typed/coordination/v1alpha2/leasecandidate.go rename to kubernetes/typed/coordination/v1alpha1/leasecandidate.go index 2939a4fc4..b8acf92d1 100644 --- a/kubernetes/typed/coordination/v1alpha2/leasecandidate.go +++ b/kubernetes/typed/coordination/v1alpha1/leasecandidate.go @@ -16,7 +16,7 @@ limitations under the License. // Code generated by kcp code-generator. DO NOT EDIT. -package v1alpha2 +package v1alpha1 import ( "context" @@ -24,10 +24,10 @@ import ( kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" "github.com/kcp-dev/logicalcluster/v3" - coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/apimachinery/pkg/watch" - coordinationv1alpha2client "k8s.io/client-go/kubernetes/typed/coordination/v1alpha2" + coordinationv1alpha1client "k8s.io/client-go/kubernetes/typed/coordination/v1alpha1" ) // LeaseCandidatesClusterGetter has a method to return a LeaseCandidateClusterInterface. @@ -40,12 +40,12 @@ type LeaseCandidatesClusterGetter interface { // or scope down to one cluster and return a LeaseCandidatesNamespacer. type LeaseCandidateClusterInterface interface { Cluster(logicalcluster.Path) LeaseCandidatesNamespacer - List(ctx context.Context, opts metav1.ListOptions) (*coordinationv1alpha2.LeaseCandidateList, error) + List(ctx context.Context, opts metav1.ListOptions) (*coordinationv1alpha1.LeaseCandidateList, error) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) } type leaseCandidatesClusterInterface struct { - clientCache kcpclient.Cache[*coordinationv1alpha2client.CoordinationV1alpha2Client] + clientCache kcpclient.Cache[*coordinationv1alpha1client.CoordinationV1alpha1Client] } // Cluster scopes the client down to a particular cluster. @@ -58,7 +58,7 @@ func (c *leaseCandidatesClusterInterface) Cluster(clusterPath logicalcluster.Pat } // List returns the entire collection of all LeaseCandidates across all clusters. -func (c *leaseCandidatesClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*coordinationv1alpha2.LeaseCandidateList, error) { +func (c *leaseCandidatesClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*coordinationv1alpha1.LeaseCandidateList, error) { return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).LeaseCandidates(metav1.NamespaceAll).List(ctx, opts) } @@ -67,16 +67,16 @@ func (c *leaseCandidatesClusterInterface) Watch(ctx context.Context, opts metav1 return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).LeaseCandidates(metav1.NamespaceAll).Watch(ctx, opts) } -// LeaseCandidatesNamespacer can scope to objects within a namespace, returning a coordinationv1alpha2client.LeaseCandidateInterface. +// LeaseCandidatesNamespacer can scope to objects within a namespace, returning a coordinationv1alpha1client.LeaseCandidateInterface. type LeaseCandidatesNamespacer interface { - Namespace(string) coordinationv1alpha2client.LeaseCandidateInterface + Namespace(string) coordinationv1alpha1client.LeaseCandidateInterface } type leaseCandidatesNamespacer struct { - clientCache kcpclient.Cache[*coordinationv1alpha2client.CoordinationV1alpha2Client] + clientCache kcpclient.Cache[*coordinationv1alpha1client.CoordinationV1alpha1Client] clusterPath logicalcluster.Path } -func (n *leaseCandidatesNamespacer) Namespace(namespace string) coordinationv1alpha2client.LeaseCandidateInterface { +func (n *leaseCandidatesNamespacer) Namespace(namespace string) coordinationv1alpha1client.LeaseCandidateInterface { return n.clientCache.ClusterOrDie(n.clusterPath).LeaseCandidates(namespace) } diff --git a/kubernetes/typed/core/v1/fake/pod.go b/kubernetes/typed/core/v1/fake/pod.go index edb818887..ed5ef08ae 100644 --- a/kubernetes/typed/core/v1/fake/pod.go +++ b/kubernetes/typed/core/v1/fake/pod.go @@ -216,11 +216,3 @@ func (c *podsClient) UpdateEphemeralContainers(ctx context.Context, podName stri } return obj.(*corev1.Pod), err } - -func (c *podsClient) UpdateResize(ctx context.Context, podName string, pod *corev1.Pod, opts metav1.UpdateOptions) (*corev1.Pod, error) { - obj, err := c.Fake.Invokes(kcptesting.NewUpdateSubresourceAction(podsResource, c.ClusterPath, "resize", c.Namespace, pod), &corev1.Pod{}) - if obj == nil { - return nil, err - } - return obj.(*corev1.Pod), err -} diff --git a/kubernetes/typed/resource/v1alpha3/fake/podschedulingcontext.go b/kubernetes/typed/resource/v1alpha3/fake/podschedulingcontext.go new file mode 100644 index 000000000..ffea16f61 --- /dev/null +++ b/kubernetes/typed/resource/v1alpha3/fake/podschedulingcontext.go @@ -0,0 +1,210 @@ +/* +Copyright The KCP 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 kcp code-generator. DO NOT EDIT. + +package fake + +import ( + "context" + "encoding/json" + "fmt" + + "github.com/kcp-dev/logicalcluster/v3" + + resourcev1alpha3 "k8s.io/api/resource/v1alpha3" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/types" + "k8s.io/apimachinery/pkg/watch" + applyconfigurationsresourcev1alpha3 "k8s.io/client-go/applyconfigurations/resource/v1alpha3" + resourcev1alpha3client "k8s.io/client-go/kubernetes/typed/resource/v1alpha3" + "k8s.io/client-go/testing" + + kcpresourcev1alpha3 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1alpha3" + kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" +) + +var podSchedulingContextsResource = schema.GroupVersionResource{Group: "resource.k8s.io", Version: "v1alpha3", Resource: "podschedulingcontexts"} +var podSchedulingContextsKind = schema.GroupVersionKind{Group: "resource.k8s.io", Version: "v1alpha3", Kind: "PodSchedulingContext"} + +type podSchedulingContextsClusterClient struct { + *kcptesting.Fake +} + +// Cluster scopes the client down to a particular cluster. +func (c *podSchedulingContextsClusterClient) Cluster(clusterPath logicalcluster.Path) kcpresourcev1alpha3.PodSchedulingContextsNamespacer { + if clusterPath == logicalcluster.Wildcard { + panic("A specific cluster must be provided when scoping, not the wildcard.") + } + + return &podSchedulingContextsNamespacer{Fake: c.Fake, ClusterPath: clusterPath} +} + +// List takes label and field selectors, and returns the list of PodSchedulingContexts that match those selectors across all clusters. +func (c *podSchedulingContextsClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1alpha3.PodSchedulingContextList, error) { + obj, err := c.Fake.Invokes(kcptesting.NewListAction(podSchedulingContextsResource, podSchedulingContextsKind, logicalcluster.Wildcard, metav1.NamespaceAll, opts), &resourcev1alpha3.PodSchedulingContextList{}) + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &resourcev1alpha3.PodSchedulingContextList{ListMeta: obj.(*resourcev1alpha3.PodSchedulingContextList).ListMeta} + for _, item := range obj.(*resourcev1alpha3.PodSchedulingContextList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +// Watch returns a watch.Interface that watches the requested PodSchedulingContexts across all clusters. +func (c *podSchedulingContextsClusterClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { + return c.Fake.InvokesWatch(kcptesting.NewWatchAction(podSchedulingContextsResource, logicalcluster.Wildcard, metav1.NamespaceAll, opts)) +} + +type podSchedulingContextsNamespacer struct { + *kcptesting.Fake + ClusterPath logicalcluster.Path +} + +func (n *podSchedulingContextsNamespacer) Namespace(namespace string) resourcev1alpha3client.PodSchedulingContextInterface { + return &podSchedulingContextsClient{Fake: n.Fake, ClusterPath: n.ClusterPath, Namespace: namespace} +} + +type podSchedulingContextsClient struct { + *kcptesting.Fake + ClusterPath logicalcluster.Path + Namespace string +} + +func (c *podSchedulingContextsClient) Create(ctx context.Context, podSchedulingContext *resourcev1alpha3.PodSchedulingContext, opts metav1.CreateOptions) (*resourcev1alpha3.PodSchedulingContext, error) { + obj, err := c.Fake.Invokes(kcptesting.NewCreateAction(podSchedulingContextsResource, c.ClusterPath, c.Namespace, podSchedulingContext), &resourcev1alpha3.PodSchedulingContext{}) + if obj == nil { + return nil, err + } + return obj.(*resourcev1alpha3.PodSchedulingContext), err +} + +func (c *podSchedulingContextsClient) Update(ctx context.Context, podSchedulingContext *resourcev1alpha3.PodSchedulingContext, opts metav1.UpdateOptions) (*resourcev1alpha3.PodSchedulingContext, error) { + obj, err := c.Fake.Invokes(kcptesting.NewUpdateAction(podSchedulingContextsResource, c.ClusterPath, c.Namespace, podSchedulingContext), &resourcev1alpha3.PodSchedulingContext{}) + if obj == nil { + return nil, err + } + return obj.(*resourcev1alpha3.PodSchedulingContext), err +} + +func (c *podSchedulingContextsClient) UpdateStatus(ctx context.Context, podSchedulingContext *resourcev1alpha3.PodSchedulingContext, opts metav1.UpdateOptions) (*resourcev1alpha3.PodSchedulingContext, error) { + obj, err := c.Fake.Invokes(kcptesting.NewUpdateSubresourceAction(podSchedulingContextsResource, c.ClusterPath, "status", c.Namespace, podSchedulingContext), &resourcev1alpha3.PodSchedulingContext{}) + if obj == nil { + return nil, err + } + return obj.(*resourcev1alpha3.PodSchedulingContext), err +} + +func (c *podSchedulingContextsClient) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { + _, err := c.Fake.Invokes(kcptesting.NewDeleteActionWithOptions(podSchedulingContextsResource, c.ClusterPath, c.Namespace, name, opts), &resourcev1alpha3.PodSchedulingContext{}) + return err +} + +func (c *podSchedulingContextsClient) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { + action := kcptesting.NewDeleteCollectionAction(podSchedulingContextsResource, c.ClusterPath, c.Namespace, listOpts) + + _, err := c.Fake.Invokes(action, &resourcev1alpha3.PodSchedulingContextList{}) + return err +} + +func (c *podSchedulingContextsClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*resourcev1alpha3.PodSchedulingContext, error) { + obj, err := c.Fake.Invokes(kcptesting.NewGetAction(podSchedulingContextsResource, c.ClusterPath, c.Namespace, name), &resourcev1alpha3.PodSchedulingContext{}) + if obj == nil { + return nil, err + } + return obj.(*resourcev1alpha3.PodSchedulingContext), err +} + +// List takes label and field selectors, and returns the list of PodSchedulingContexts that match those selectors. +func (c *podSchedulingContextsClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1alpha3.PodSchedulingContextList, error) { + obj, err := c.Fake.Invokes(kcptesting.NewListAction(podSchedulingContextsResource, podSchedulingContextsKind, c.ClusterPath, c.Namespace, opts), &resourcev1alpha3.PodSchedulingContextList{}) + if obj == nil { + return nil, err + } + + label, _, _ := testing.ExtractFromListOptions(opts) + if label == nil { + label = labels.Everything() + } + list := &resourcev1alpha3.PodSchedulingContextList{ListMeta: obj.(*resourcev1alpha3.PodSchedulingContextList).ListMeta} + for _, item := range obj.(*resourcev1alpha3.PodSchedulingContextList).Items { + if label.Matches(labels.Set(item.Labels)) { + list.Items = append(list.Items, item) + } + } + return list, err +} + +func (c *podSchedulingContextsClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { + return c.Fake.InvokesWatch(kcptesting.NewWatchAction(podSchedulingContextsResource, c.ClusterPath, c.Namespace, opts)) +} + +func (c *podSchedulingContextsClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*resourcev1alpha3.PodSchedulingContext, error) { + obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(podSchedulingContextsResource, c.ClusterPath, c.Namespace, name, pt, data, subresources...), &resourcev1alpha3.PodSchedulingContext{}) + if obj == nil { + return nil, err + } + return obj.(*resourcev1alpha3.PodSchedulingContext), err +} + +func (c *podSchedulingContextsClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1alpha3.PodSchedulingContextApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1alpha3.PodSchedulingContext, error) { + if applyConfiguration == nil { + return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") + } + data, err := json.Marshal(applyConfiguration) + if err != nil { + return nil, err + } + name := applyConfiguration.Name + if name == nil { + return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") + } + obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(podSchedulingContextsResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data), &resourcev1alpha3.PodSchedulingContext{}) + if obj == nil { + return nil, err + } + return obj.(*resourcev1alpha3.PodSchedulingContext), err +} + +func (c *podSchedulingContextsClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1alpha3.PodSchedulingContextApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1alpha3.PodSchedulingContext, error) { + if applyConfiguration == nil { + return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") + } + data, err := json.Marshal(applyConfiguration) + if err != nil { + return nil, err + } + name := applyConfiguration.Name + if name == nil { + return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") + } + obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(podSchedulingContextsResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data, "status"), &resourcev1alpha3.PodSchedulingContext{}) + if obj == nil { + return nil, err + } + return obj.(*resourcev1alpha3.PodSchedulingContext), err +} diff --git a/kubernetes/typed/resource/v1alpha3/fake/resource_client.go b/kubernetes/typed/resource/v1alpha3/fake/resource_client.go index 26d9ac861..03e3fb07e 100644 --- a/kubernetes/typed/resource/v1alpha3/fake/resource_client.go +++ b/kubernetes/typed/resource/v1alpha3/fake/resource_client.go @@ -49,6 +49,10 @@ func (c *ResourceV1alpha3ClusterClient) ResourceClaims() kcpresourcev1alpha3.Res return &resourceClaimsClusterClient{Fake: c.Fake} } +func (c *ResourceV1alpha3ClusterClient) PodSchedulingContexts() kcpresourcev1alpha3.PodSchedulingContextClusterInterface { + return &podSchedulingContextsClusterClient{Fake: c.Fake} +} + func (c *ResourceV1alpha3ClusterClient) DeviceClasses() kcpresourcev1alpha3.DeviceClassClusterInterface { return &deviceClassesClusterClient{Fake: c.Fake} } @@ -77,6 +81,10 @@ func (c *ResourceV1alpha3Client) ResourceClaims(namespace string) resourcev1alph return &resourceClaimsClient{Fake: c.Fake, ClusterPath: c.ClusterPath, Namespace: namespace} } +func (c *ResourceV1alpha3Client) PodSchedulingContexts(namespace string) resourcev1alpha3.PodSchedulingContextInterface { + return &podSchedulingContextsClient{Fake: c.Fake, ClusterPath: c.ClusterPath, Namespace: namespace} +} + func (c *ResourceV1alpha3Client) DeviceClasses() resourcev1alpha3.DeviceClassInterface { return &deviceClassesClient{Fake: c.Fake, ClusterPath: c.ClusterPath} } diff --git a/kubernetes/typed/resource/v1alpha3/podschedulingcontext.go b/kubernetes/typed/resource/v1alpha3/podschedulingcontext.go new file mode 100644 index 000000000..ac0eccead --- /dev/null +++ b/kubernetes/typed/resource/v1alpha3/podschedulingcontext.go @@ -0,0 +1,82 @@ +/* +Copyright The KCP 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 kcp code-generator. DO NOT EDIT. + +package v1alpha3 + +import ( + "context" + + kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" + "github.com/kcp-dev/logicalcluster/v3" + + resourcev1alpha3 "k8s.io/api/resource/v1alpha3" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/watch" + resourcev1alpha3client "k8s.io/client-go/kubernetes/typed/resource/v1alpha3" +) + +// PodSchedulingContextsClusterGetter has a method to return a PodSchedulingContextClusterInterface. +// A group's cluster client should implement this interface. +type PodSchedulingContextsClusterGetter interface { + PodSchedulingContexts() PodSchedulingContextClusterInterface +} + +// PodSchedulingContextClusterInterface can operate on PodSchedulingContexts across all clusters, +// or scope down to one cluster and return a PodSchedulingContextsNamespacer. +type PodSchedulingContextClusterInterface interface { + Cluster(logicalcluster.Path) PodSchedulingContextsNamespacer + List(ctx context.Context, opts metav1.ListOptions) (*resourcev1alpha3.PodSchedulingContextList, error) + Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) +} + +type podSchedulingContextsClusterInterface struct { + clientCache kcpclient.Cache[*resourcev1alpha3client.ResourceV1alpha3Client] +} + +// Cluster scopes the client down to a particular cluster. +func (c *podSchedulingContextsClusterInterface) Cluster(clusterPath logicalcluster.Path) PodSchedulingContextsNamespacer { + if clusterPath == logicalcluster.Wildcard { + panic("A specific cluster must be provided when scoping, not the wildcard.") + } + + return &podSchedulingContextsNamespacer{clientCache: c.clientCache, clusterPath: clusterPath} +} + +// List returns the entire collection of all PodSchedulingContexts across all clusters. +func (c *podSchedulingContextsClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1alpha3.PodSchedulingContextList, error) { + return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).PodSchedulingContexts(metav1.NamespaceAll).List(ctx, opts) +} + +// Watch begins to watch all PodSchedulingContexts across all clusters. +func (c *podSchedulingContextsClusterInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { + return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).PodSchedulingContexts(metav1.NamespaceAll).Watch(ctx, opts) +} + +// PodSchedulingContextsNamespacer can scope to objects within a namespace, returning a resourcev1alpha3client.PodSchedulingContextInterface. +type PodSchedulingContextsNamespacer interface { + Namespace(string) resourcev1alpha3client.PodSchedulingContextInterface +} + +type podSchedulingContextsNamespacer struct { + clientCache kcpclient.Cache[*resourcev1alpha3client.ResourceV1alpha3Client] + clusterPath logicalcluster.Path +} + +func (n *podSchedulingContextsNamespacer) Namespace(namespace string) resourcev1alpha3client.PodSchedulingContextInterface { + return n.clientCache.ClusterOrDie(n.clusterPath).PodSchedulingContexts(namespace) +} diff --git a/kubernetes/typed/resource/v1alpha3/resource_client.go b/kubernetes/typed/resource/v1alpha3/resource_client.go index 655573331..5bf4ab174 100644 --- a/kubernetes/typed/resource/v1alpha3/resource_client.go +++ b/kubernetes/typed/resource/v1alpha3/resource_client.go @@ -32,6 +32,7 @@ type ResourceV1alpha3ClusterInterface interface { ResourceV1alpha3ClusterScoper ResourceSlicesClusterGetter ResourceClaimsClusterGetter + PodSchedulingContextsClusterGetter DeviceClassesClusterGetter ResourceClaimTemplatesClusterGetter } @@ -59,6 +60,10 @@ func (c *ResourceV1alpha3ClusterClient) ResourceClaims() ResourceClaimClusterInt return &resourceClaimsClusterInterface{clientCache: c.clientCache} } +func (c *ResourceV1alpha3ClusterClient) PodSchedulingContexts() PodSchedulingContextClusterInterface { + return &podSchedulingContextsClusterInterface{clientCache: c.clientCache} +} + func (c *ResourceV1alpha3ClusterClient) DeviceClasses() DeviceClassClusterInterface { return &deviceClassesClusterInterface{clientCache: c.clientCache} } diff --git a/kubernetes/typed/resource/v1beta1/deviceclass.go b/kubernetes/typed/resource/v1beta1/deviceclass.go deleted file mode 100644 index e6ebe014d..000000000 --- a/kubernetes/typed/resource/v1beta1/deviceclass.go +++ /dev/null @@ -1,68 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "context" - - kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/watch" - resourcev1beta1client "k8s.io/client-go/kubernetes/typed/resource/v1beta1" -) - -// DeviceClassesClusterGetter has a method to return a DeviceClassClusterInterface. -// A group's cluster client should implement this interface. -type DeviceClassesClusterGetter interface { - DeviceClasses() DeviceClassClusterInterface -} - -// DeviceClassClusterInterface can operate on DeviceClasses across all clusters, -// or scope down to one cluster and return a resourcev1beta1client.DeviceClassInterface. -type DeviceClassClusterInterface interface { - Cluster(logicalcluster.Path) resourcev1beta1client.DeviceClassInterface - List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.DeviceClassList, error) - Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) -} - -type deviceClassesClusterInterface struct { - clientCache kcpclient.Cache[*resourcev1beta1client.ResourceV1beta1Client] -} - -// Cluster scopes the client down to a particular cluster. -func (c *deviceClassesClusterInterface) Cluster(clusterPath logicalcluster.Path) resourcev1beta1client.DeviceClassInterface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return c.clientCache.ClusterOrDie(clusterPath).DeviceClasses() -} - -// List returns the entire collection of all DeviceClasses across all clusters. -func (c *deviceClassesClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.DeviceClassList, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).DeviceClasses().List(ctx, opts) -} - -// Watch begins to watch all DeviceClasses across all clusters. -func (c *deviceClassesClusterInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).DeviceClasses().Watch(ctx, opts) -} diff --git a/kubernetes/typed/resource/v1beta1/fake/deviceclass.go b/kubernetes/typed/resource/v1beta1/fake/deviceclass.go deleted file mode 100644 index b64a51cff..000000000 --- a/kubernetes/typed/resource/v1beta1/fake/deviceclass.go +++ /dev/null @@ -1,199 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package fake - -import ( - "context" - "encoding/json" - "fmt" - - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/labels" - "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/apimachinery/pkg/types" - "k8s.io/apimachinery/pkg/watch" - applyconfigurationsresourcev1beta1 "k8s.io/client-go/applyconfigurations/resource/v1beta1" - resourcev1beta1client "k8s.io/client-go/kubernetes/typed/resource/v1beta1" - "k8s.io/client-go/testing" - - kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" -) - -var deviceClassesResource = schema.GroupVersionResource{Group: "resource.k8s.io", Version: "v1beta1", Resource: "deviceclasses"} -var deviceClassesKind = schema.GroupVersionKind{Group: "resource.k8s.io", Version: "v1beta1", Kind: "DeviceClass"} - -type deviceClassesClusterClient struct { - *kcptesting.Fake -} - -// Cluster scopes the client down to a particular cluster. -func (c *deviceClassesClusterClient) Cluster(clusterPath logicalcluster.Path) resourcev1beta1client.DeviceClassInterface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return &deviceClassesClient{Fake: c.Fake, ClusterPath: clusterPath} -} - -// List takes label and field selectors, and returns the list of DeviceClasses that match those selectors across all clusters. -func (c *deviceClassesClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.DeviceClassList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootListAction(deviceClassesResource, deviceClassesKind, logicalcluster.Wildcard, opts), &resourcev1beta1.DeviceClassList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &resourcev1beta1.DeviceClassList{ListMeta: obj.(*resourcev1beta1.DeviceClassList).ListMeta} - for _, item := range obj.(*resourcev1beta1.DeviceClassList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -// Watch returns a watch.Interface that watches the requested DeviceClasses across all clusters. -func (c *deviceClassesClusterClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewRootWatchAction(deviceClassesResource, logicalcluster.Wildcard, opts)) -} - -type deviceClassesClient struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path -} - -func (c *deviceClassesClient) Create(ctx context.Context, deviceClass *resourcev1beta1.DeviceClass, opts metav1.CreateOptions) (*resourcev1beta1.DeviceClass, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootCreateAction(deviceClassesResource, c.ClusterPath, deviceClass), &resourcev1beta1.DeviceClass{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.DeviceClass), err -} - -func (c *deviceClassesClient) Update(ctx context.Context, deviceClass *resourcev1beta1.DeviceClass, opts metav1.UpdateOptions) (*resourcev1beta1.DeviceClass, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootUpdateAction(deviceClassesResource, c.ClusterPath, deviceClass), &resourcev1beta1.DeviceClass{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.DeviceClass), err -} - -func (c *deviceClassesClient) UpdateStatus(ctx context.Context, deviceClass *resourcev1beta1.DeviceClass, opts metav1.UpdateOptions) (*resourcev1beta1.DeviceClass, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootUpdateSubresourceAction(deviceClassesResource, c.ClusterPath, "status", deviceClass), &resourcev1beta1.DeviceClass{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.DeviceClass), err -} - -func (c *deviceClassesClient) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { - _, err := c.Fake.Invokes(kcptesting.NewRootDeleteActionWithOptions(deviceClassesResource, c.ClusterPath, name, opts), &resourcev1beta1.DeviceClass{}) - return err -} - -func (c *deviceClassesClient) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { - action := kcptesting.NewRootDeleteCollectionAction(deviceClassesResource, c.ClusterPath, listOpts) - - _, err := c.Fake.Invokes(action, &resourcev1beta1.DeviceClassList{}) - return err -} - -func (c *deviceClassesClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*resourcev1beta1.DeviceClass, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootGetAction(deviceClassesResource, c.ClusterPath, name), &resourcev1beta1.DeviceClass{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.DeviceClass), err -} - -// List takes label and field selectors, and returns the list of DeviceClasses that match those selectors. -func (c *deviceClassesClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.DeviceClassList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootListAction(deviceClassesResource, deviceClassesKind, c.ClusterPath, opts), &resourcev1beta1.DeviceClassList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &resourcev1beta1.DeviceClassList{ListMeta: obj.(*resourcev1beta1.DeviceClassList).ListMeta} - for _, item := range obj.(*resourcev1beta1.DeviceClassList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -func (c *deviceClassesClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewRootWatchAction(deviceClassesResource, c.ClusterPath, opts)) -} - -func (c *deviceClassesClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*resourcev1beta1.DeviceClass, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(deviceClassesResource, c.ClusterPath, name, pt, data, subresources...), &resourcev1beta1.DeviceClass{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.DeviceClass), err -} - -func (c *deviceClassesClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1beta1.DeviceClassApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1beta1.DeviceClass, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(deviceClassesResource, c.ClusterPath, *name, types.ApplyPatchType, data), &resourcev1beta1.DeviceClass{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.DeviceClass), err -} - -func (c *deviceClassesClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1beta1.DeviceClassApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1beta1.DeviceClass, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(deviceClassesResource, c.ClusterPath, *name, types.ApplyPatchType, data, "status"), &resourcev1beta1.DeviceClass{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.DeviceClass), err -} diff --git a/kubernetes/typed/resource/v1beta1/fake/resource_client.go b/kubernetes/typed/resource/v1beta1/fake/resource_client.go deleted file mode 100644 index f65f2118b..000000000 --- a/kubernetes/typed/resource/v1beta1/fake/resource_client.go +++ /dev/null @@ -1,86 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package fake - -import ( - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1" - "k8s.io/client-go/rest" - - kcpresourcev1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1beta1" - kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" -) - -var _ kcpresourcev1beta1.ResourceV1beta1ClusterInterface = (*ResourceV1beta1ClusterClient)(nil) - -type ResourceV1beta1ClusterClient struct { - *kcptesting.Fake -} - -func (c *ResourceV1beta1ClusterClient) Cluster(clusterPath logicalcluster.Path) resourcev1beta1.ResourceV1beta1Interface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - return &ResourceV1beta1Client{Fake: c.Fake, ClusterPath: clusterPath} -} - -func (c *ResourceV1beta1ClusterClient) ResourceSlices() kcpresourcev1beta1.ResourceSliceClusterInterface { - return &resourceSlicesClusterClient{Fake: c.Fake} -} - -func (c *ResourceV1beta1ClusterClient) ResourceClaims() kcpresourcev1beta1.ResourceClaimClusterInterface { - return &resourceClaimsClusterClient{Fake: c.Fake} -} - -func (c *ResourceV1beta1ClusterClient) DeviceClasses() kcpresourcev1beta1.DeviceClassClusterInterface { - return &deviceClassesClusterClient{Fake: c.Fake} -} - -func (c *ResourceV1beta1ClusterClient) ResourceClaimTemplates() kcpresourcev1beta1.ResourceClaimTemplateClusterInterface { - return &resourceClaimTemplatesClusterClient{Fake: c.Fake} -} - -var _ resourcev1beta1.ResourceV1beta1Interface = (*ResourceV1beta1Client)(nil) - -type ResourceV1beta1Client struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path -} - -func (c *ResourceV1beta1Client) RESTClient() rest.Interface { - var ret *rest.RESTClient - return ret -} - -func (c *ResourceV1beta1Client) ResourceSlices() resourcev1beta1.ResourceSliceInterface { - return &resourceSlicesClient{Fake: c.Fake, ClusterPath: c.ClusterPath} -} - -func (c *ResourceV1beta1Client) ResourceClaims(namespace string) resourcev1beta1.ResourceClaimInterface { - return &resourceClaimsClient{Fake: c.Fake, ClusterPath: c.ClusterPath, Namespace: namespace} -} - -func (c *ResourceV1beta1Client) DeviceClasses() resourcev1beta1.DeviceClassInterface { - return &deviceClassesClient{Fake: c.Fake, ClusterPath: c.ClusterPath} -} - -func (c *ResourceV1beta1Client) ResourceClaimTemplates(namespace string) resourcev1beta1.ResourceClaimTemplateInterface { - return &resourceClaimTemplatesClient{Fake: c.Fake, ClusterPath: c.ClusterPath, Namespace: namespace} -} diff --git a/kubernetes/typed/resource/v1beta1/fake/resourceclaim.go b/kubernetes/typed/resource/v1beta1/fake/resourceclaim.go deleted file mode 100644 index d7c7d98fe..000000000 --- a/kubernetes/typed/resource/v1beta1/fake/resourceclaim.go +++ /dev/null @@ -1,210 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package fake - -import ( - "context" - "encoding/json" - "fmt" - - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/labels" - "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/apimachinery/pkg/types" - "k8s.io/apimachinery/pkg/watch" - applyconfigurationsresourcev1beta1 "k8s.io/client-go/applyconfigurations/resource/v1beta1" - resourcev1beta1client "k8s.io/client-go/kubernetes/typed/resource/v1beta1" - "k8s.io/client-go/testing" - - kcpresourcev1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1beta1" - kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" -) - -var resourceClaimsResource = schema.GroupVersionResource{Group: "resource.k8s.io", Version: "v1beta1", Resource: "resourceclaims"} -var resourceClaimsKind = schema.GroupVersionKind{Group: "resource.k8s.io", Version: "v1beta1", Kind: "ResourceClaim"} - -type resourceClaimsClusterClient struct { - *kcptesting.Fake -} - -// Cluster scopes the client down to a particular cluster. -func (c *resourceClaimsClusterClient) Cluster(clusterPath logicalcluster.Path) kcpresourcev1beta1.ResourceClaimsNamespacer { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return &resourceClaimsNamespacer{Fake: c.Fake, ClusterPath: clusterPath} -} - -// List takes label and field selectors, and returns the list of ResourceClaims that match those selectors across all clusters. -func (c *resourceClaimsClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceClaimList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewListAction(resourceClaimsResource, resourceClaimsKind, logicalcluster.Wildcard, metav1.NamespaceAll, opts), &resourcev1beta1.ResourceClaimList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &resourcev1beta1.ResourceClaimList{ListMeta: obj.(*resourcev1beta1.ResourceClaimList).ListMeta} - for _, item := range obj.(*resourcev1beta1.ResourceClaimList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -// Watch returns a watch.Interface that watches the requested ResourceClaims across all clusters. -func (c *resourceClaimsClusterClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewWatchAction(resourceClaimsResource, logicalcluster.Wildcard, metav1.NamespaceAll, opts)) -} - -type resourceClaimsNamespacer struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path -} - -func (n *resourceClaimsNamespacer) Namespace(namespace string) resourcev1beta1client.ResourceClaimInterface { - return &resourceClaimsClient{Fake: n.Fake, ClusterPath: n.ClusterPath, Namespace: namespace} -} - -type resourceClaimsClient struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path - Namespace string -} - -func (c *resourceClaimsClient) Create(ctx context.Context, resourceClaim *resourcev1beta1.ResourceClaim, opts metav1.CreateOptions) (*resourcev1beta1.ResourceClaim, error) { - obj, err := c.Fake.Invokes(kcptesting.NewCreateAction(resourceClaimsResource, c.ClusterPath, c.Namespace, resourceClaim), &resourcev1beta1.ResourceClaim{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaim), err -} - -func (c *resourceClaimsClient) Update(ctx context.Context, resourceClaim *resourcev1beta1.ResourceClaim, opts metav1.UpdateOptions) (*resourcev1beta1.ResourceClaim, error) { - obj, err := c.Fake.Invokes(kcptesting.NewUpdateAction(resourceClaimsResource, c.ClusterPath, c.Namespace, resourceClaim), &resourcev1beta1.ResourceClaim{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaim), err -} - -func (c *resourceClaimsClient) UpdateStatus(ctx context.Context, resourceClaim *resourcev1beta1.ResourceClaim, opts metav1.UpdateOptions) (*resourcev1beta1.ResourceClaim, error) { - obj, err := c.Fake.Invokes(kcptesting.NewUpdateSubresourceAction(resourceClaimsResource, c.ClusterPath, "status", c.Namespace, resourceClaim), &resourcev1beta1.ResourceClaim{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaim), err -} - -func (c *resourceClaimsClient) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { - _, err := c.Fake.Invokes(kcptesting.NewDeleteActionWithOptions(resourceClaimsResource, c.ClusterPath, c.Namespace, name, opts), &resourcev1beta1.ResourceClaim{}) - return err -} - -func (c *resourceClaimsClient) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { - action := kcptesting.NewDeleteCollectionAction(resourceClaimsResource, c.ClusterPath, c.Namespace, listOpts) - - _, err := c.Fake.Invokes(action, &resourcev1beta1.ResourceClaimList{}) - return err -} - -func (c *resourceClaimsClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*resourcev1beta1.ResourceClaim, error) { - obj, err := c.Fake.Invokes(kcptesting.NewGetAction(resourceClaimsResource, c.ClusterPath, c.Namespace, name), &resourcev1beta1.ResourceClaim{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaim), err -} - -// List takes label and field selectors, and returns the list of ResourceClaims that match those selectors. -func (c *resourceClaimsClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceClaimList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewListAction(resourceClaimsResource, resourceClaimsKind, c.ClusterPath, c.Namespace, opts), &resourcev1beta1.ResourceClaimList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &resourcev1beta1.ResourceClaimList{ListMeta: obj.(*resourcev1beta1.ResourceClaimList).ListMeta} - for _, item := range obj.(*resourcev1beta1.ResourceClaimList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -func (c *resourceClaimsClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewWatchAction(resourceClaimsResource, c.ClusterPath, c.Namespace, opts)) -} - -func (c *resourceClaimsClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*resourcev1beta1.ResourceClaim, error) { - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(resourceClaimsResource, c.ClusterPath, c.Namespace, name, pt, data, subresources...), &resourcev1beta1.ResourceClaim{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaim), err -} - -func (c *resourceClaimsClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1beta1.ResourceClaimApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1beta1.ResourceClaim, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(resourceClaimsResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data), &resourcev1beta1.ResourceClaim{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaim), err -} - -func (c *resourceClaimsClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1beta1.ResourceClaimApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1beta1.ResourceClaim, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(resourceClaimsResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data, "status"), &resourcev1beta1.ResourceClaim{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaim), err -} diff --git a/kubernetes/typed/resource/v1beta1/fake/resourceclaimtemplate.go b/kubernetes/typed/resource/v1beta1/fake/resourceclaimtemplate.go deleted file mode 100644 index c17473b27..000000000 --- a/kubernetes/typed/resource/v1beta1/fake/resourceclaimtemplate.go +++ /dev/null @@ -1,210 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package fake - -import ( - "context" - "encoding/json" - "fmt" - - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/labels" - "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/apimachinery/pkg/types" - "k8s.io/apimachinery/pkg/watch" - applyconfigurationsresourcev1beta1 "k8s.io/client-go/applyconfigurations/resource/v1beta1" - resourcev1beta1client "k8s.io/client-go/kubernetes/typed/resource/v1beta1" - "k8s.io/client-go/testing" - - kcpresourcev1beta1 "github.com/kcp-dev/client-go/kubernetes/typed/resource/v1beta1" - kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" -) - -var resourceClaimTemplatesResource = schema.GroupVersionResource{Group: "resource.k8s.io", Version: "v1beta1", Resource: "resourceclaimtemplates"} -var resourceClaimTemplatesKind = schema.GroupVersionKind{Group: "resource.k8s.io", Version: "v1beta1", Kind: "ResourceClaimTemplate"} - -type resourceClaimTemplatesClusterClient struct { - *kcptesting.Fake -} - -// Cluster scopes the client down to a particular cluster. -func (c *resourceClaimTemplatesClusterClient) Cluster(clusterPath logicalcluster.Path) kcpresourcev1beta1.ResourceClaimTemplatesNamespacer { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return &resourceClaimTemplatesNamespacer{Fake: c.Fake, ClusterPath: clusterPath} -} - -// List takes label and field selectors, and returns the list of ResourceClaimTemplates that match those selectors across all clusters. -func (c *resourceClaimTemplatesClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceClaimTemplateList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewListAction(resourceClaimTemplatesResource, resourceClaimTemplatesKind, logicalcluster.Wildcard, metav1.NamespaceAll, opts), &resourcev1beta1.ResourceClaimTemplateList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &resourcev1beta1.ResourceClaimTemplateList{ListMeta: obj.(*resourcev1beta1.ResourceClaimTemplateList).ListMeta} - for _, item := range obj.(*resourcev1beta1.ResourceClaimTemplateList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -// Watch returns a watch.Interface that watches the requested ResourceClaimTemplates across all clusters. -func (c *resourceClaimTemplatesClusterClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewWatchAction(resourceClaimTemplatesResource, logicalcluster.Wildcard, metav1.NamespaceAll, opts)) -} - -type resourceClaimTemplatesNamespacer struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path -} - -func (n *resourceClaimTemplatesNamespacer) Namespace(namespace string) resourcev1beta1client.ResourceClaimTemplateInterface { - return &resourceClaimTemplatesClient{Fake: n.Fake, ClusterPath: n.ClusterPath, Namespace: namespace} -} - -type resourceClaimTemplatesClient struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path - Namespace string -} - -func (c *resourceClaimTemplatesClient) Create(ctx context.Context, resourceClaimTemplate *resourcev1beta1.ResourceClaimTemplate, opts metav1.CreateOptions) (*resourcev1beta1.ResourceClaimTemplate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewCreateAction(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, resourceClaimTemplate), &resourcev1beta1.ResourceClaimTemplate{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaimTemplate), err -} - -func (c *resourceClaimTemplatesClient) Update(ctx context.Context, resourceClaimTemplate *resourcev1beta1.ResourceClaimTemplate, opts metav1.UpdateOptions) (*resourcev1beta1.ResourceClaimTemplate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewUpdateAction(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, resourceClaimTemplate), &resourcev1beta1.ResourceClaimTemplate{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaimTemplate), err -} - -func (c *resourceClaimTemplatesClient) UpdateStatus(ctx context.Context, resourceClaimTemplate *resourcev1beta1.ResourceClaimTemplate, opts metav1.UpdateOptions) (*resourcev1beta1.ResourceClaimTemplate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewUpdateSubresourceAction(resourceClaimTemplatesResource, c.ClusterPath, "status", c.Namespace, resourceClaimTemplate), &resourcev1beta1.ResourceClaimTemplate{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaimTemplate), err -} - -func (c *resourceClaimTemplatesClient) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { - _, err := c.Fake.Invokes(kcptesting.NewDeleteActionWithOptions(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, name, opts), &resourcev1beta1.ResourceClaimTemplate{}) - return err -} - -func (c *resourceClaimTemplatesClient) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { - action := kcptesting.NewDeleteCollectionAction(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, listOpts) - - _, err := c.Fake.Invokes(action, &resourcev1beta1.ResourceClaimTemplateList{}) - return err -} - -func (c *resourceClaimTemplatesClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*resourcev1beta1.ResourceClaimTemplate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewGetAction(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, name), &resourcev1beta1.ResourceClaimTemplate{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaimTemplate), err -} - -// List takes label and field selectors, and returns the list of ResourceClaimTemplates that match those selectors. -func (c *resourceClaimTemplatesClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceClaimTemplateList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewListAction(resourceClaimTemplatesResource, resourceClaimTemplatesKind, c.ClusterPath, c.Namespace, opts), &resourcev1beta1.ResourceClaimTemplateList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &resourcev1beta1.ResourceClaimTemplateList{ListMeta: obj.(*resourcev1beta1.ResourceClaimTemplateList).ListMeta} - for _, item := range obj.(*resourcev1beta1.ResourceClaimTemplateList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -func (c *resourceClaimTemplatesClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewWatchAction(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, opts)) -} - -func (c *resourceClaimTemplatesClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*resourcev1beta1.ResourceClaimTemplate, error) { - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, name, pt, data, subresources...), &resourcev1beta1.ResourceClaimTemplate{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaimTemplate), err -} - -func (c *resourceClaimTemplatesClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1beta1.ResourceClaimTemplateApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1beta1.ResourceClaimTemplate, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data), &resourcev1beta1.ResourceClaimTemplate{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaimTemplate), err -} - -func (c *resourceClaimTemplatesClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1beta1.ResourceClaimTemplateApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1beta1.ResourceClaimTemplate, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewPatchSubresourceAction(resourceClaimTemplatesResource, c.ClusterPath, c.Namespace, *name, types.ApplyPatchType, data, "status"), &resourcev1beta1.ResourceClaimTemplate{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceClaimTemplate), err -} diff --git a/kubernetes/typed/resource/v1beta1/fake/resourceslice.go b/kubernetes/typed/resource/v1beta1/fake/resourceslice.go deleted file mode 100644 index 3870fdf50..000000000 --- a/kubernetes/typed/resource/v1beta1/fake/resourceslice.go +++ /dev/null @@ -1,199 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package fake - -import ( - "context" - "encoding/json" - "fmt" - - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/labels" - "k8s.io/apimachinery/pkg/runtime/schema" - "k8s.io/apimachinery/pkg/types" - "k8s.io/apimachinery/pkg/watch" - applyconfigurationsresourcev1beta1 "k8s.io/client-go/applyconfigurations/resource/v1beta1" - resourcev1beta1client "k8s.io/client-go/kubernetes/typed/resource/v1beta1" - "k8s.io/client-go/testing" - - kcptesting "github.com/kcp-dev/client-go/third_party/k8s.io/client-go/testing" -) - -var resourceSlicesResource = schema.GroupVersionResource{Group: "resource.k8s.io", Version: "v1beta1", Resource: "resourceslices"} -var resourceSlicesKind = schema.GroupVersionKind{Group: "resource.k8s.io", Version: "v1beta1", Kind: "ResourceSlice"} - -type resourceSlicesClusterClient struct { - *kcptesting.Fake -} - -// Cluster scopes the client down to a particular cluster. -func (c *resourceSlicesClusterClient) Cluster(clusterPath logicalcluster.Path) resourcev1beta1client.ResourceSliceInterface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return &resourceSlicesClient{Fake: c.Fake, ClusterPath: clusterPath} -} - -// List takes label and field selectors, and returns the list of ResourceSlices that match those selectors across all clusters. -func (c *resourceSlicesClusterClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceSliceList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootListAction(resourceSlicesResource, resourceSlicesKind, logicalcluster.Wildcard, opts), &resourcev1beta1.ResourceSliceList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &resourcev1beta1.ResourceSliceList{ListMeta: obj.(*resourcev1beta1.ResourceSliceList).ListMeta} - for _, item := range obj.(*resourcev1beta1.ResourceSliceList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -// Watch returns a watch.Interface that watches the requested ResourceSlices across all clusters. -func (c *resourceSlicesClusterClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewRootWatchAction(resourceSlicesResource, logicalcluster.Wildcard, opts)) -} - -type resourceSlicesClient struct { - *kcptesting.Fake - ClusterPath logicalcluster.Path -} - -func (c *resourceSlicesClient) Create(ctx context.Context, resourceSlice *resourcev1beta1.ResourceSlice, opts metav1.CreateOptions) (*resourcev1beta1.ResourceSlice, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootCreateAction(resourceSlicesResource, c.ClusterPath, resourceSlice), &resourcev1beta1.ResourceSlice{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceSlice), err -} - -func (c *resourceSlicesClient) Update(ctx context.Context, resourceSlice *resourcev1beta1.ResourceSlice, opts metav1.UpdateOptions) (*resourcev1beta1.ResourceSlice, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootUpdateAction(resourceSlicesResource, c.ClusterPath, resourceSlice), &resourcev1beta1.ResourceSlice{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceSlice), err -} - -func (c *resourceSlicesClient) UpdateStatus(ctx context.Context, resourceSlice *resourcev1beta1.ResourceSlice, opts metav1.UpdateOptions) (*resourcev1beta1.ResourceSlice, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootUpdateSubresourceAction(resourceSlicesResource, c.ClusterPath, "status", resourceSlice), &resourcev1beta1.ResourceSlice{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceSlice), err -} - -func (c *resourceSlicesClient) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { - _, err := c.Fake.Invokes(kcptesting.NewRootDeleteActionWithOptions(resourceSlicesResource, c.ClusterPath, name, opts), &resourcev1beta1.ResourceSlice{}) - return err -} - -func (c *resourceSlicesClient) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { - action := kcptesting.NewRootDeleteCollectionAction(resourceSlicesResource, c.ClusterPath, listOpts) - - _, err := c.Fake.Invokes(action, &resourcev1beta1.ResourceSliceList{}) - return err -} - -func (c *resourceSlicesClient) Get(ctx context.Context, name string, options metav1.GetOptions) (*resourcev1beta1.ResourceSlice, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootGetAction(resourceSlicesResource, c.ClusterPath, name), &resourcev1beta1.ResourceSlice{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceSlice), err -} - -// List takes label and field selectors, and returns the list of ResourceSlices that match those selectors. -func (c *resourceSlicesClient) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceSliceList, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootListAction(resourceSlicesResource, resourceSlicesKind, c.ClusterPath, opts), &resourcev1beta1.ResourceSliceList{}) - if obj == nil { - return nil, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &resourcev1beta1.ResourceSliceList{ListMeta: obj.(*resourcev1beta1.ResourceSliceList).ListMeta} - for _, item := range obj.(*resourcev1beta1.ResourceSliceList).Items { - if label.Matches(labels.Set(item.Labels)) { - list.Items = append(list.Items, item) - } - } - return list, err -} - -func (c *resourceSlicesClient) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake.InvokesWatch(kcptesting.NewRootWatchAction(resourceSlicesResource, c.ClusterPath, opts)) -} - -func (c *resourceSlicesClient) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (*resourcev1beta1.ResourceSlice, error) { - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(resourceSlicesResource, c.ClusterPath, name, pt, data, subresources...), &resourcev1beta1.ResourceSlice{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceSlice), err -} - -func (c *resourceSlicesClient) Apply(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1beta1.ResourceSliceApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1beta1.ResourceSlice, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(resourceSlicesResource, c.ClusterPath, *name, types.ApplyPatchType, data), &resourcev1beta1.ResourceSlice{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceSlice), err -} - -func (c *resourceSlicesClient) ApplyStatus(ctx context.Context, applyConfiguration *applyconfigurationsresourcev1beta1.ResourceSliceApplyConfiguration, opts metav1.ApplyOptions) (*resourcev1beta1.ResourceSlice, error) { - if applyConfiguration == nil { - return nil, fmt.Errorf("applyConfiguration provided to Apply must not be nil") - } - data, err := json.Marshal(applyConfiguration) - if err != nil { - return nil, err - } - name := applyConfiguration.Name - if name == nil { - return nil, fmt.Errorf("applyConfiguration.Name must be provided to Apply") - } - obj, err := c.Fake.Invokes(kcptesting.NewRootPatchSubresourceAction(resourceSlicesResource, c.ClusterPath, *name, types.ApplyPatchType, data, "status"), &resourcev1beta1.ResourceSlice{}) - if obj == nil { - return nil, err - } - return obj.(*resourcev1beta1.ResourceSlice), err -} diff --git a/kubernetes/typed/resource/v1beta1/resource_client.go b/kubernetes/typed/resource/v1beta1/resource_client.go deleted file mode 100644 index 99b247244..000000000 --- a/kubernetes/typed/resource/v1beta1/resource_client.go +++ /dev/null @@ -1,101 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "net/http" - - kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/client-go/kubernetes/typed/resource/v1beta1" - "k8s.io/client-go/rest" -) - -type ResourceV1beta1ClusterInterface interface { - ResourceV1beta1ClusterScoper - ResourceSlicesClusterGetter - ResourceClaimsClusterGetter - DeviceClassesClusterGetter - ResourceClaimTemplatesClusterGetter -} - -type ResourceV1beta1ClusterScoper interface { - Cluster(logicalcluster.Path) resourcev1beta1.ResourceV1beta1Interface -} - -type ResourceV1beta1ClusterClient struct { - clientCache kcpclient.Cache[*resourcev1beta1.ResourceV1beta1Client] -} - -func (c *ResourceV1beta1ClusterClient) Cluster(clusterPath logicalcluster.Path) resourcev1beta1.ResourceV1beta1Interface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - return c.clientCache.ClusterOrDie(clusterPath) -} - -func (c *ResourceV1beta1ClusterClient) ResourceSlices() ResourceSliceClusterInterface { - return &resourceSlicesClusterInterface{clientCache: c.clientCache} -} - -func (c *ResourceV1beta1ClusterClient) ResourceClaims() ResourceClaimClusterInterface { - return &resourceClaimsClusterInterface{clientCache: c.clientCache} -} - -func (c *ResourceV1beta1ClusterClient) DeviceClasses() DeviceClassClusterInterface { - return &deviceClassesClusterInterface{clientCache: c.clientCache} -} - -func (c *ResourceV1beta1ClusterClient) ResourceClaimTemplates() ResourceClaimTemplateClusterInterface { - return &resourceClaimTemplatesClusterInterface{clientCache: c.clientCache} -} - -// NewForConfig creates a new ResourceV1beta1ClusterClient for the given config. -// NewForConfig is equivalent to NewForConfigAndClient(c, httpClient), -// where httpClient was generated with rest.HTTPClientFor(c). -func NewForConfig(c *rest.Config) (*ResourceV1beta1ClusterClient, error) { - client, err := rest.HTTPClientFor(c) - if err != nil { - return nil, err - } - return NewForConfigAndClient(c, client) -} - -// NewForConfigAndClient creates a new ResourceV1beta1ClusterClient for the given config and http client. -// Note the http client provided takes precedence over the configured transport values. -func NewForConfigAndClient(c *rest.Config, h *http.Client) (*ResourceV1beta1ClusterClient, error) { - cache := kcpclient.NewCache(c, h, &kcpclient.Constructor[*resourcev1beta1.ResourceV1beta1Client]{ - NewForConfigAndClient: resourcev1beta1.NewForConfigAndClient, - }) - if _, err := cache.Cluster(logicalcluster.Name("root").Path()); err != nil { - return nil, err - } - return &ResourceV1beta1ClusterClient{clientCache: cache}, nil -} - -// NewForConfigOrDie creates a new ResourceV1beta1ClusterClient for the given config and -// panics if there is an error in the config. -func NewForConfigOrDie(c *rest.Config) *ResourceV1beta1ClusterClient { - client, err := NewForConfig(c) - if err != nil { - panic(err) - } - return client -} diff --git a/kubernetes/typed/resource/v1beta1/resourceclaim.go b/kubernetes/typed/resource/v1beta1/resourceclaim.go deleted file mode 100644 index 096d479f6..000000000 --- a/kubernetes/typed/resource/v1beta1/resourceclaim.go +++ /dev/null @@ -1,82 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "context" - - kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/watch" - resourcev1beta1client "k8s.io/client-go/kubernetes/typed/resource/v1beta1" -) - -// ResourceClaimsClusterGetter has a method to return a ResourceClaimClusterInterface. -// A group's cluster client should implement this interface. -type ResourceClaimsClusterGetter interface { - ResourceClaims() ResourceClaimClusterInterface -} - -// ResourceClaimClusterInterface can operate on ResourceClaims across all clusters, -// or scope down to one cluster and return a ResourceClaimsNamespacer. -type ResourceClaimClusterInterface interface { - Cluster(logicalcluster.Path) ResourceClaimsNamespacer - List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceClaimList, error) - Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) -} - -type resourceClaimsClusterInterface struct { - clientCache kcpclient.Cache[*resourcev1beta1client.ResourceV1beta1Client] -} - -// Cluster scopes the client down to a particular cluster. -func (c *resourceClaimsClusterInterface) Cluster(clusterPath logicalcluster.Path) ResourceClaimsNamespacer { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return &resourceClaimsNamespacer{clientCache: c.clientCache, clusterPath: clusterPath} -} - -// List returns the entire collection of all ResourceClaims across all clusters. -func (c *resourceClaimsClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceClaimList, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).ResourceClaims(metav1.NamespaceAll).List(ctx, opts) -} - -// Watch begins to watch all ResourceClaims across all clusters. -func (c *resourceClaimsClusterInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).ResourceClaims(metav1.NamespaceAll).Watch(ctx, opts) -} - -// ResourceClaimsNamespacer can scope to objects within a namespace, returning a resourcev1beta1client.ResourceClaimInterface. -type ResourceClaimsNamespacer interface { - Namespace(string) resourcev1beta1client.ResourceClaimInterface -} - -type resourceClaimsNamespacer struct { - clientCache kcpclient.Cache[*resourcev1beta1client.ResourceV1beta1Client] - clusterPath logicalcluster.Path -} - -func (n *resourceClaimsNamespacer) Namespace(namespace string) resourcev1beta1client.ResourceClaimInterface { - return n.clientCache.ClusterOrDie(n.clusterPath).ResourceClaims(namespace) -} diff --git a/kubernetes/typed/resource/v1beta1/resourceclaimtemplate.go b/kubernetes/typed/resource/v1beta1/resourceclaimtemplate.go deleted file mode 100644 index 086d7d852..000000000 --- a/kubernetes/typed/resource/v1beta1/resourceclaimtemplate.go +++ /dev/null @@ -1,82 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "context" - - kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/watch" - resourcev1beta1client "k8s.io/client-go/kubernetes/typed/resource/v1beta1" -) - -// ResourceClaimTemplatesClusterGetter has a method to return a ResourceClaimTemplateClusterInterface. -// A group's cluster client should implement this interface. -type ResourceClaimTemplatesClusterGetter interface { - ResourceClaimTemplates() ResourceClaimTemplateClusterInterface -} - -// ResourceClaimTemplateClusterInterface can operate on ResourceClaimTemplates across all clusters, -// or scope down to one cluster and return a ResourceClaimTemplatesNamespacer. -type ResourceClaimTemplateClusterInterface interface { - Cluster(logicalcluster.Path) ResourceClaimTemplatesNamespacer - List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceClaimTemplateList, error) - Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) -} - -type resourceClaimTemplatesClusterInterface struct { - clientCache kcpclient.Cache[*resourcev1beta1client.ResourceV1beta1Client] -} - -// Cluster scopes the client down to a particular cluster. -func (c *resourceClaimTemplatesClusterInterface) Cluster(clusterPath logicalcluster.Path) ResourceClaimTemplatesNamespacer { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return &resourceClaimTemplatesNamespacer{clientCache: c.clientCache, clusterPath: clusterPath} -} - -// List returns the entire collection of all ResourceClaimTemplates across all clusters. -func (c *resourceClaimTemplatesClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceClaimTemplateList, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).ResourceClaimTemplates(metav1.NamespaceAll).List(ctx, opts) -} - -// Watch begins to watch all ResourceClaimTemplates across all clusters. -func (c *resourceClaimTemplatesClusterInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).ResourceClaimTemplates(metav1.NamespaceAll).Watch(ctx, opts) -} - -// ResourceClaimTemplatesNamespacer can scope to objects within a namespace, returning a resourcev1beta1client.ResourceClaimTemplateInterface. -type ResourceClaimTemplatesNamespacer interface { - Namespace(string) resourcev1beta1client.ResourceClaimTemplateInterface -} - -type resourceClaimTemplatesNamespacer struct { - clientCache kcpclient.Cache[*resourcev1beta1client.ResourceV1beta1Client] - clusterPath logicalcluster.Path -} - -func (n *resourceClaimTemplatesNamespacer) Namespace(namespace string) resourcev1beta1client.ResourceClaimTemplateInterface { - return n.clientCache.ClusterOrDie(n.clusterPath).ResourceClaimTemplates(namespace) -} diff --git a/kubernetes/typed/resource/v1beta1/resourceslice.go b/kubernetes/typed/resource/v1beta1/resourceslice.go deleted file mode 100644 index 045aef833..000000000 --- a/kubernetes/typed/resource/v1beta1/resourceslice.go +++ /dev/null @@ -1,68 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - "context" - - kcpclient "github.com/kcp-dev/apimachinery/v2/pkg/client" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - "k8s.io/apimachinery/pkg/watch" - resourcev1beta1client "k8s.io/client-go/kubernetes/typed/resource/v1beta1" -) - -// ResourceSlicesClusterGetter has a method to return a ResourceSliceClusterInterface. -// A group's cluster client should implement this interface. -type ResourceSlicesClusterGetter interface { - ResourceSlices() ResourceSliceClusterInterface -} - -// ResourceSliceClusterInterface can operate on ResourceSlices across all clusters, -// or scope down to one cluster and return a resourcev1beta1client.ResourceSliceInterface. -type ResourceSliceClusterInterface interface { - Cluster(logicalcluster.Path) resourcev1beta1client.ResourceSliceInterface - List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceSliceList, error) - Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) -} - -type resourceSlicesClusterInterface struct { - clientCache kcpclient.Cache[*resourcev1beta1client.ResourceV1beta1Client] -} - -// Cluster scopes the client down to a particular cluster. -func (c *resourceSlicesClusterInterface) Cluster(clusterPath logicalcluster.Path) resourcev1beta1client.ResourceSliceInterface { - if clusterPath == logicalcluster.Wildcard { - panic("A specific cluster must be provided when scoping, not the wildcard.") - } - - return c.clientCache.ClusterOrDie(clusterPath).ResourceSlices() -} - -// List returns the entire collection of all ResourceSlices across all clusters. -func (c *resourceSlicesClusterInterface) List(ctx context.Context, opts metav1.ListOptions) (*resourcev1beta1.ResourceSliceList, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).ResourceSlices().List(ctx, opts) -} - -// Watch begins to watch all ResourceSlices across all clusters. -func (c *resourceSlicesClusterInterface) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.clientCache.ClusterOrDie(logicalcluster.Wildcard).ResourceSlices().Watch(ctx, opts) -} diff --git a/listers/admissionregistration/v1/mutatingwebhookconfiguration_expansion.go b/listers/admissionregistration/v1/mutatingwebhookconfiguration_expansion.go index ad9ad945b..a5e155e39 100644 --- a/listers/admissionregistration/v1/mutatingwebhookconfiguration_expansion.go +++ b/listers/admissionregistration/v1/mutatingwebhookconfiguration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1/validatingadmissionpolicy_expansion.go b/listers/admissionregistration/v1/validatingadmissionpolicy_expansion.go index 29fbe81fa..726ce2ea4 100644 --- a/listers/admissionregistration/v1/validatingadmissionpolicy_expansion.go +++ b/listers/admissionregistration/v1/validatingadmissionpolicy_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1/validatingadmissionpolicybinding_expansion.go b/listers/admissionregistration/v1/validatingadmissionpolicybinding_expansion.go index 0adb47da3..d1deade29 100644 --- a/listers/admissionregistration/v1/validatingadmissionpolicybinding_expansion.go +++ b/listers/admissionregistration/v1/validatingadmissionpolicybinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1/validatingwebhookconfiguration_expansion.go b/listers/admissionregistration/v1/validatingwebhookconfiguration_expansion.go index bb551f8ed..f7aa161de 100644 --- a/listers/admissionregistration/v1/validatingwebhookconfiguration_expansion.go +++ b/listers/admissionregistration/v1/validatingwebhookconfiguration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1alpha1/mutatingadmissionpolicy.go b/listers/admissionregistration/v1alpha1/mutatingadmissionpolicy.go deleted file mode 100644 index 6c9cfc205..000000000 --- a/listers/admissionregistration/v1alpha1/mutatingadmissionpolicy.go +++ /dev/null @@ -1,94 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1alpha1 - -import ( - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - "github.com/kcp-dev/logicalcluster/v3" - - admissionregistrationv1alpha1 "k8s.io/api/admissionregistration/v1alpha1" - "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/labels" - admissionregistrationv1alpha1listers "k8s.io/client-go/listers/admissionregistration/v1alpha1" - "k8s.io/client-go/tools/cache" -) - -// MutatingAdmissionPolicyClusterLister can list MutatingAdmissionPolicies across all workspaces, or scope down to a MutatingAdmissionPolicyLister for one workspace. -// All objects returned here must be treated as read-only. -type MutatingAdmissionPolicyClusterLister interface { - // List lists all MutatingAdmissionPolicies in the indexer. - // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*admissionregistrationv1alpha1.MutatingAdmissionPolicy, err error) - // Cluster returns a lister that can list and get MutatingAdmissionPolicies in one workspace. - Cluster(clusterName logicalcluster.Name) admissionregistrationv1alpha1listers.MutatingAdmissionPolicyLister - MutatingAdmissionPolicyClusterListerExpansion -} - -type mutatingAdmissionPolicyClusterLister struct { - indexer cache.Indexer -} - -// NewMutatingAdmissionPolicyClusterLister returns a new MutatingAdmissionPolicyClusterLister. -// We assume that the indexer: -// - is fed by a cross-workspace LIST+WATCH -// - uses kcpcache.MetaClusterNamespaceKeyFunc as the key function -// - has the kcpcache.ClusterIndex as an index -func NewMutatingAdmissionPolicyClusterLister(indexer cache.Indexer) *mutatingAdmissionPolicyClusterLister { - return &mutatingAdmissionPolicyClusterLister{indexer: indexer} -} - -// List lists all MutatingAdmissionPolicies in the indexer across all workspaces. -func (s *mutatingAdmissionPolicyClusterLister) List(selector labels.Selector) (ret []*admissionregistrationv1alpha1.MutatingAdmissionPolicy, err error) { - err = cache.ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy)) - }) - return ret, err -} - -// Cluster scopes the lister to one workspace, allowing users to list and get MutatingAdmissionPolicies. -func (s *mutatingAdmissionPolicyClusterLister) Cluster(clusterName logicalcluster.Name) admissionregistrationv1alpha1listers.MutatingAdmissionPolicyLister { - return &mutatingAdmissionPolicyLister{indexer: s.indexer, clusterName: clusterName} -} - -// mutatingAdmissionPolicyLister implements the admissionregistrationv1alpha1listers.MutatingAdmissionPolicyLister interface. -type mutatingAdmissionPolicyLister struct { - indexer cache.Indexer - clusterName logicalcluster.Name -} - -// List lists all MutatingAdmissionPolicies in the indexer for a workspace. -func (s *mutatingAdmissionPolicyLister) List(selector labels.Selector) (ret []*admissionregistrationv1alpha1.MutatingAdmissionPolicy, err error) { - err = kcpcache.ListAllByCluster(s.indexer, s.clusterName, selector, func(i interface{}) { - ret = append(ret, i.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy)) - }) - return ret, err -} - -// Get retrieves the MutatingAdmissionPolicy from the indexer for a given workspace and name. -func (s *mutatingAdmissionPolicyLister) Get(name string) (*admissionregistrationv1alpha1.MutatingAdmissionPolicy, error) { - key := kcpcache.ToClusterAwareKey(s.clusterName.String(), "", name) - obj, exists, err := s.indexer.GetByKey(key) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(admissionregistrationv1alpha1.Resource("mutatingadmissionpolicies"), name) - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicy), nil -} diff --git a/listers/admissionregistration/v1alpha1/mutatingadmissionpolicy_expansion.go b/listers/admissionregistration/v1alpha1/mutatingadmissionpolicy_expansion.go deleted file mode 100644 index 44362c26a..000000000 --- a/listers/admissionregistration/v1alpha1/mutatingadmissionpolicy_expansion.go +++ /dev/null @@ -1,22 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1alpha1 - -// MutatingAdmissionPolicyClusterListerExpansion allows custom methods to be added to MutatingAdmissionPolicyClusterLister. -type MutatingAdmissionPolicyClusterListerExpansion interface{} diff --git a/listers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go b/listers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go deleted file mode 100644 index 34b6ce417..000000000 --- a/listers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding.go +++ /dev/null @@ -1,94 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1alpha1 - -import ( - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - "github.com/kcp-dev/logicalcluster/v3" - - admissionregistrationv1alpha1 "k8s.io/api/admissionregistration/v1alpha1" - "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/labels" - admissionregistrationv1alpha1listers "k8s.io/client-go/listers/admissionregistration/v1alpha1" - "k8s.io/client-go/tools/cache" -) - -// MutatingAdmissionPolicyBindingClusterLister can list MutatingAdmissionPolicyBindings across all workspaces, or scope down to a MutatingAdmissionPolicyBindingLister for one workspace. -// All objects returned here must be treated as read-only. -type MutatingAdmissionPolicyBindingClusterLister interface { - // List lists all MutatingAdmissionPolicyBindings in the indexer. - // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, err error) - // Cluster returns a lister that can list and get MutatingAdmissionPolicyBindings in one workspace. - Cluster(clusterName logicalcluster.Name) admissionregistrationv1alpha1listers.MutatingAdmissionPolicyBindingLister - MutatingAdmissionPolicyBindingClusterListerExpansion -} - -type mutatingAdmissionPolicyBindingClusterLister struct { - indexer cache.Indexer -} - -// NewMutatingAdmissionPolicyBindingClusterLister returns a new MutatingAdmissionPolicyBindingClusterLister. -// We assume that the indexer: -// - is fed by a cross-workspace LIST+WATCH -// - uses kcpcache.MetaClusterNamespaceKeyFunc as the key function -// - has the kcpcache.ClusterIndex as an index -func NewMutatingAdmissionPolicyBindingClusterLister(indexer cache.Indexer) *mutatingAdmissionPolicyBindingClusterLister { - return &mutatingAdmissionPolicyBindingClusterLister{indexer: indexer} -} - -// List lists all MutatingAdmissionPolicyBindings in the indexer across all workspaces. -func (s *mutatingAdmissionPolicyBindingClusterLister) List(selector labels.Selector) (ret []*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, err error) { - err = cache.ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding)) - }) - return ret, err -} - -// Cluster scopes the lister to one workspace, allowing users to list and get MutatingAdmissionPolicyBindings. -func (s *mutatingAdmissionPolicyBindingClusterLister) Cluster(clusterName logicalcluster.Name) admissionregistrationv1alpha1listers.MutatingAdmissionPolicyBindingLister { - return &mutatingAdmissionPolicyBindingLister{indexer: s.indexer, clusterName: clusterName} -} - -// mutatingAdmissionPolicyBindingLister implements the admissionregistrationv1alpha1listers.MutatingAdmissionPolicyBindingLister interface. -type mutatingAdmissionPolicyBindingLister struct { - indexer cache.Indexer - clusterName logicalcluster.Name -} - -// List lists all MutatingAdmissionPolicyBindings in the indexer for a workspace. -func (s *mutatingAdmissionPolicyBindingLister) List(selector labels.Selector) (ret []*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, err error) { - err = kcpcache.ListAllByCluster(s.indexer, s.clusterName, selector, func(i interface{}) { - ret = append(ret, i.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding)) - }) - return ret, err -} - -// Get retrieves the MutatingAdmissionPolicyBinding from the indexer for a given workspace and name. -func (s *mutatingAdmissionPolicyBindingLister) Get(name string) (*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding, error) { - key := kcpcache.ToClusterAwareKey(s.clusterName.String(), "", name) - obj, exists, err := s.indexer.GetByKey(key) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(admissionregistrationv1alpha1.Resource("mutatingadmissionpolicybindings"), name) - } - return obj.(*admissionregistrationv1alpha1.MutatingAdmissionPolicyBinding), nil -} diff --git a/listers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding_expansion.go b/listers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding_expansion.go deleted file mode 100644 index cccaebc0f..000000000 --- a/listers/admissionregistration/v1alpha1/mutatingadmissionpolicybinding_expansion.go +++ /dev/null @@ -1,22 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1alpha1 - -// MutatingAdmissionPolicyBindingClusterListerExpansion allows custom methods to be added to MutatingAdmissionPolicyBindingClusterLister. -type MutatingAdmissionPolicyBindingClusterListerExpansion interface{} diff --git a/listers/admissionregistration/v1alpha1/validatingadmissionpolicy_expansion.go b/listers/admissionregistration/v1alpha1/validatingadmissionpolicy_expansion.go index edbb3d388..d9b418cd5 100644 --- a/listers/admissionregistration/v1alpha1/validatingadmissionpolicy_expansion.go +++ b/listers/admissionregistration/v1alpha1/validatingadmissionpolicy_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1alpha1/validatingadmissionpolicybinding_expansion.go b/listers/admissionregistration/v1alpha1/validatingadmissionpolicybinding_expansion.go index b08ac3f77..ee8b51134 100644 --- a/listers/admissionregistration/v1alpha1/validatingadmissionpolicybinding_expansion.go +++ b/listers/admissionregistration/v1alpha1/validatingadmissionpolicybinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1beta1/mutatingwebhookconfiguration_expansion.go b/listers/admissionregistration/v1beta1/mutatingwebhookconfiguration_expansion.go index cb7937733..dc0b6257a 100644 --- a/listers/admissionregistration/v1beta1/mutatingwebhookconfiguration_expansion.go +++ b/listers/admissionregistration/v1beta1/mutatingwebhookconfiguration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1beta1/validatingadmissionpolicy_expansion.go b/listers/admissionregistration/v1beta1/validatingadmissionpolicy_expansion.go index e954f6319..b5632aad5 100644 --- a/listers/admissionregistration/v1beta1/validatingadmissionpolicy_expansion.go +++ b/listers/admissionregistration/v1beta1/validatingadmissionpolicy_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1beta1/validatingadmissionpolicybinding_expansion.go b/listers/admissionregistration/v1beta1/validatingadmissionpolicybinding_expansion.go index ccfd6a32d..00a24cabb 100644 --- a/listers/admissionregistration/v1beta1/validatingadmissionpolicybinding_expansion.go +++ b/listers/admissionregistration/v1beta1/validatingadmissionpolicybinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/admissionregistration/v1beta1/validatingwebhookconfiguration_expansion.go b/listers/admissionregistration/v1beta1/validatingwebhookconfiguration_expansion.go index ce50f471d..f3e99e6fb 100644 --- a/listers/admissionregistration/v1beta1/validatingwebhookconfiguration_expansion.go +++ b/listers/admissionregistration/v1beta1/validatingwebhookconfiguration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/apiserverinternal/v1alpha1/storageversion_expansion.go b/listers/apiserverinternal/v1alpha1/storageversion_expansion.go index 63038d3f2..8e2db395c 100644 --- a/listers/apiserverinternal/v1alpha1/storageversion_expansion.go +++ b/listers/apiserverinternal/v1alpha1/storageversion_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/apps/v1/controllerrevision_expansion.go b/listers/apps/v1/controllerrevision_expansion.go index 121e47ec6..066da888a 100644 --- a/listers/apps/v1/controllerrevision_expansion.go +++ b/listers/apps/v1/controllerrevision_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/apps/v1/deployment_expansion.go b/listers/apps/v1/deployment_expansion.go index b0dcdac73..eb37c3f65 100644 --- a/listers/apps/v1/deployment_expansion.go +++ b/listers/apps/v1/deployment_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/apps/v1beta1/controllerrevision_expansion.go b/listers/apps/v1beta1/controllerrevision_expansion.go index c0745283c..431159d57 100644 --- a/listers/apps/v1beta1/controllerrevision_expansion.go +++ b/listers/apps/v1beta1/controllerrevision_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/apps/v1beta1/deployment_expansion.go b/listers/apps/v1beta1/deployment_expansion.go index 11a6cf51c..3c43c24f7 100644 --- a/listers/apps/v1beta1/deployment_expansion.go +++ b/listers/apps/v1beta1/deployment_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/apps/v1beta2/controllerrevision_expansion.go b/listers/apps/v1beta2/controllerrevision_expansion.go index 0bb948b3e..6dc8757e2 100644 --- a/listers/apps/v1beta2/controllerrevision_expansion.go +++ b/listers/apps/v1beta2/controllerrevision_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/apps/v1beta2/deployment_expansion.go b/listers/apps/v1beta2/deployment_expansion.go index df847acec..9464078de 100644 --- a/listers/apps/v1beta2/deployment_expansion.go +++ b/listers/apps/v1beta2/deployment_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/autoscaling/v1/horizontalpodautoscaler_expansion.go b/listers/autoscaling/v1/horizontalpodautoscaler_expansion.go index 65785806b..860110654 100644 --- a/listers/autoscaling/v1/horizontalpodautoscaler_expansion.go +++ b/listers/autoscaling/v1/horizontalpodautoscaler_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/autoscaling/v2/horizontalpodautoscaler_expansion.go b/listers/autoscaling/v2/horizontalpodautoscaler_expansion.go index f186ef85d..57334c551 100644 --- a/listers/autoscaling/v2/horizontalpodautoscaler_expansion.go +++ b/listers/autoscaling/v2/horizontalpodautoscaler_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/autoscaling/v2beta1/horizontalpodautoscaler_expansion.go b/listers/autoscaling/v2beta1/horizontalpodautoscaler_expansion.go index 30954c982..d7993a256 100644 --- a/listers/autoscaling/v2beta1/horizontalpodautoscaler_expansion.go +++ b/listers/autoscaling/v2beta1/horizontalpodautoscaler_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/autoscaling/v2beta2/horizontalpodautoscaler_expansion.go b/listers/autoscaling/v2beta2/horizontalpodautoscaler_expansion.go index 9d264c8ef..b5624ae75 100644 --- a/listers/autoscaling/v2beta2/horizontalpodautoscaler_expansion.go +++ b/listers/autoscaling/v2beta2/horizontalpodautoscaler_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/batch/v1/cronjob_expansion.go b/listers/batch/v1/cronjob_expansion.go index b398acdae..41c86205c 100644 --- a/listers/batch/v1/cronjob_expansion.go +++ b/listers/batch/v1/cronjob_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/batch/v1beta1/cronjob_expansion.go b/listers/batch/v1beta1/cronjob_expansion.go index a9de967e3..c8bed8a7e 100644 --- a/listers/batch/v1beta1/cronjob_expansion.go +++ b/listers/batch/v1beta1/cronjob_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/certificates/v1/certificatesigningrequest_expansion.go b/listers/certificates/v1/certificatesigningrequest_expansion.go index 35c07886d..a3eed0c84 100644 --- a/listers/certificates/v1/certificatesigningrequest_expansion.go +++ b/listers/certificates/v1/certificatesigningrequest_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/certificates/v1alpha1/clustertrustbundle_expansion.go b/listers/certificates/v1alpha1/clustertrustbundle_expansion.go index 4a8a493e7..96e41b1bd 100644 --- a/listers/certificates/v1alpha1/clustertrustbundle_expansion.go +++ b/listers/certificates/v1alpha1/clustertrustbundle_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/certificates/v1beta1/certificatesigningrequest_expansion.go b/listers/certificates/v1beta1/certificatesigningrequest_expansion.go index 91dc37427..8f1bc06dd 100644 --- a/listers/certificates/v1beta1/certificatesigningrequest_expansion.go +++ b/listers/certificates/v1beta1/certificatesigningrequest_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/coordination/v1/lease_expansion.go b/listers/coordination/v1/lease_expansion.go index 614b152fb..70360ca1e 100644 --- a/listers/coordination/v1/lease_expansion.go +++ b/listers/coordination/v1/lease_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/coordination/v1alpha2/leasecandidate.go b/listers/coordination/v1alpha1/leasecandidate.go similarity index 78% rename from listers/coordination/v1alpha2/leasecandidate.go rename to listers/coordination/v1alpha1/leasecandidate.go index 0beb46398..43ea27638 100644 --- a/listers/coordination/v1alpha2/leasecandidate.go +++ b/listers/coordination/v1alpha1/leasecandidate.go @@ -16,16 +16,16 @@ limitations under the License. // Code generated by kcp code-generator. DO NOT EDIT. -package v1alpha2 +package v1alpha1 import ( kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" "github.com/kcp-dev/logicalcluster/v3" - coordinationv1alpha2 "k8s.io/api/coordination/v1alpha2" + coordinationv1alpha1 "k8s.io/api/coordination/v1alpha1" "k8s.io/apimachinery/pkg/api/errors" "k8s.io/apimachinery/pkg/labels" - coordinationv1alpha2listers "k8s.io/client-go/listers/coordination/v1alpha2" + coordinationv1alpha1listers "k8s.io/client-go/listers/coordination/v1alpha1" "k8s.io/client-go/tools/cache" ) @@ -34,9 +34,9 @@ import ( type LeaseCandidateClusterLister interface { // List lists all LeaseCandidates in the indexer. // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*coordinationv1alpha2.LeaseCandidate, err error) + List(selector labels.Selector) (ret []*coordinationv1alpha1.LeaseCandidate, err error) // Cluster returns a lister that can list and get LeaseCandidates in one workspace. - Cluster(clusterName logicalcluster.Name) coordinationv1alpha2listers.LeaseCandidateLister + Cluster(clusterName logicalcluster.Name) coordinationv1alpha1listers.LeaseCandidateLister LeaseCandidateClusterListerExpansion } @@ -55,38 +55,38 @@ func NewLeaseCandidateClusterLister(indexer cache.Indexer) *leaseCandidateCluste } // List lists all LeaseCandidates in the indexer across all workspaces. -func (s *leaseCandidateClusterLister) List(selector labels.Selector) (ret []*coordinationv1alpha2.LeaseCandidate, err error) { +func (s *leaseCandidateClusterLister) List(selector labels.Selector) (ret []*coordinationv1alpha1.LeaseCandidate, err error) { err = cache.ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*coordinationv1alpha2.LeaseCandidate)) + ret = append(ret, m.(*coordinationv1alpha1.LeaseCandidate)) }) return ret, err } // Cluster scopes the lister to one workspace, allowing users to list and get LeaseCandidates. -func (s *leaseCandidateClusterLister) Cluster(clusterName logicalcluster.Name) coordinationv1alpha2listers.LeaseCandidateLister { +func (s *leaseCandidateClusterLister) Cluster(clusterName logicalcluster.Name) coordinationv1alpha1listers.LeaseCandidateLister { return &leaseCandidateLister{indexer: s.indexer, clusterName: clusterName} } -// leaseCandidateLister implements the coordinationv1alpha2listers.LeaseCandidateLister interface. +// leaseCandidateLister implements the coordinationv1alpha1listers.LeaseCandidateLister interface. type leaseCandidateLister struct { indexer cache.Indexer clusterName logicalcluster.Name } // List lists all LeaseCandidates in the indexer for a workspace. -func (s *leaseCandidateLister) List(selector labels.Selector) (ret []*coordinationv1alpha2.LeaseCandidate, err error) { +func (s *leaseCandidateLister) List(selector labels.Selector) (ret []*coordinationv1alpha1.LeaseCandidate, err error) { err = kcpcache.ListAllByCluster(s.indexer, s.clusterName, selector, func(i interface{}) { - ret = append(ret, i.(*coordinationv1alpha2.LeaseCandidate)) + ret = append(ret, i.(*coordinationv1alpha1.LeaseCandidate)) }) return ret, err } // LeaseCandidates returns an object that can list and get LeaseCandidates in one namespace. -func (s *leaseCandidateLister) LeaseCandidates(namespace string) coordinationv1alpha2listers.LeaseCandidateNamespaceLister { +func (s *leaseCandidateLister) LeaseCandidates(namespace string) coordinationv1alpha1listers.LeaseCandidateNamespaceLister { return &leaseCandidateNamespaceLister{indexer: s.indexer, clusterName: s.clusterName, namespace: namespace} } -// leaseCandidateNamespaceLister implements the coordinationv1alpha2listers.LeaseCandidateNamespaceLister interface. +// leaseCandidateNamespaceLister implements the coordinationv1alpha1listers.LeaseCandidateNamespaceLister interface. type leaseCandidateNamespaceLister struct { indexer cache.Indexer clusterName logicalcluster.Name @@ -94,22 +94,22 @@ type leaseCandidateNamespaceLister struct { } // List lists all LeaseCandidates in the indexer for a given workspace and namespace. -func (s *leaseCandidateNamespaceLister) List(selector labels.Selector) (ret []*coordinationv1alpha2.LeaseCandidate, err error) { +func (s *leaseCandidateNamespaceLister) List(selector labels.Selector) (ret []*coordinationv1alpha1.LeaseCandidate, err error) { err = kcpcache.ListAllByClusterAndNamespace(s.indexer, s.clusterName, s.namespace, selector, func(i interface{}) { - ret = append(ret, i.(*coordinationv1alpha2.LeaseCandidate)) + ret = append(ret, i.(*coordinationv1alpha1.LeaseCandidate)) }) return ret, err } // Get retrieves the LeaseCandidate from the indexer for a given workspace, namespace and name. -func (s *leaseCandidateNamespaceLister) Get(name string) (*coordinationv1alpha2.LeaseCandidate, error) { +func (s *leaseCandidateNamespaceLister) Get(name string) (*coordinationv1alpha1.LeaseCandidate, error) { key := kcpcache.ToClusterAwareKey(s.clusterName.String(), s.namespace, name) obj, exists, err := s.indexer.GetByKey(key) if err != nil { return nil, err } if !exists { - return nil, errors.NewNotFound(coordinationv1alpha2.Resource("leasecandidates"), name) + return nil, errors.NewNotFound(coordinationv1alpha1.Resource("leasecandidates"), name) } - return obj.(*coordinationv1alpha2.LeaseCandidate), nil + return obj.(*coordinationv1alpha1.LeaseCandidate), nil } diff --git a/listers/coordination/v1alpha2/leasecandidate_expansion.go b/listers/coordination/v1alpha1/leasecandidate_expansion.go similarity index 97% rename from listers/coordination/v1alpha2/leasecandidate_expansion.go rename to listers/coordination/v1alpha1/leasecandidate_expansion.go index e7111c298..87a2472b8 100644 --- a/listers/coordination/v1alpha2/leasecandidate_expansion.go +++ b/listers/coordination/v1alpha1/leasecandidate_expansion.go @@ -16,7 +16,7 @@ limitations under the License. // Code generated by kcp code-generator. DO NOT EDIT. -package v1alpha2 +package v1alpha1 // LeaseCandidateClusterListerExpansion allows custom methods to be added to LeaseCandidateClusterLister. type LeaseCandidateClusterListerExpansion interface{} diff --git a/listers/coordination/v1beta1/lease_expansion.go b/listers/coordination/v1beta1/lease_expansion.go index 0f27bbd50..379bafcd5 100644 --- a/listers/coordination/v1beta1/lease_expansion.go +++ b/listers/coordination/v1beta1/lease_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/componentstatus_expansion.go b/listers/core/v1/componentstatus_expansion.go index 68585eb2b..301d9113a 100644 --- a/listers/core/v1/componentstatus_expansion.go +++ b/listers/core/v1/componentstatus_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/configmap_expansion.go b/listers/core/v1/configmap_expansion.go index 42a2c1707..67ab850e3 100644 --- a/listers/core/v1/configmap_expansion.go +++ b/listers/core/v1/configmap_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/endpoints_expansion.go b/listers/core/v1/endpoints_expansion.go index 8183e8065..099ab4270 100644 --- a/listers/core/v1/endpoints_expansion.go +++ b/listers/core/v1/endpoints_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/event_expansion.go b/listers/core/v1/event_expansion.go index bdb79e6ed..d43a29751 100644 --- a/listers/core/v1/event_expansion.go +++ b/listers/core/v1/event_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/limitrange_expansion.go b/listers/core/v1/limitrange_expansion.go index 7c72c7177..eb916f700 100644 --- a/listers/core/v1/limitrange_expansion.go +++ b/listers/core/v1/limitrange_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/namespace_expansion.go b/listers/core/v1/namespace_expansion.go index ea8e99ced..cd7eb0f54 100644 --- a/listers/core/v1/namespace_expansion.go +++ b/listers/core/v1/namespace_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/node_expansion.go b/listers/core/v1/node_expansion.go index 3a2f35bfd..4c228c130 100644 --- a/listers/core/v1/node_expansion.go +++ b/listers/core/v1/node_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/persistentvolume_expansion.go b/listers/core/v1/persistentvolume_expansion.go index 1cf27f753..8b21ac0ab 100644 --- a/listers/core/v1/persistentvolume_expansion.go +++ b/listers/core/v1/persistentvolume_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/persistentvolumeclaim_expansion.go b/listers/core/v1/persistentvolumeclaim_expansion.go index 94e33ca0b..107f37297 100644 --- a/listers/core/v1/persistentvolumeclaim_expansion.go +++ b/listers/core/v1/persistentvolumeclaim_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/pod_expansion.go b/listers/core/v1/pod_expansion.go index e4bfca6a6..05fac6885 100644 --- a/listers/core/v1/pod_expansion.go +++ b/listers/core/v1/pod_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/podtemplate_expansion.go b/listers/core/v1/podtemplate_expansion.go index 778cf1723..485c13260 100644 --- a/listers/core/v1/podtemplate_expansion.go +++ b/listers/core/v1/podtemplate_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/resourcequota_expansion.go b/listers/core/v1/resourcequota_expansion.go index a7d6eaed9..98776b0ff 100644 --- a/listers/core/v1/resourcequota_expansion.go +++ b/listers/core/v1/resourcequota_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/secret_expansion.go b/listers/core/v1/secret_expansion.go index 717fd920c..72bc44feb 100644 --- a/listers/core/v1/secret_expansion.go +++ b/listers/core/v1/secret_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/service_expansion.go b/listers/core/v1/service_expansion.go index c9c2c3af3..c812d5019 100644 --- a/listers/core/v1/service_expansion.go +++ b/listers/core/v1/service_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/core/v1/serviceaccount_expansion.go b/listers/core/v1/serviceaccount_expansion.go index 4d4047a51..f8042e1b5 100644 --- a/listers/core/v1/serviceaccount_expansion.go +++ b/listers/core/v1/serviceaccount_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/discovery/v1/endpointslice_expansion.go b/listers/discovery/v1/endpointslice_expansion.go index 35e480934..298e5f701 100644 --- a/listers/discovery/v1/endpointslice_expansion.go +++ b/listers/discovery/v1/endpointslice_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/discovery/v1beta1/endpointslice_expansion.go b/listers/discovery/v1beta1/endpointslice_expansion.go index 8e5c10af3..8103228ee 100644 --- a/listers/discovery/v1beta1/endpointslice_expansion.go +++ b/listers/discovery/v1beta1/endpointslice_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/events/v1/event_expansion.go b/listers/events/v1/event_expansion.go index bdb79e6ed..d43a29751 100644 --- a/listers/events/v1/event_expansion.go +++ b/listers/events/v1/event_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/events/v1beta1/event_expansion.go b/listers/events/v1beta1/event_expansion.go index c9901ed25..c1472469a 100644 --- a/listers/events/v1beta1/event_expansion.go +++ b/listers/events/v1beta1/event_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/extensions/v1beta1/deployment_expansion.go b/listers/extensions/v1beta1/deployment_expansion.go index 11a6cf51c..3c43c24f7 100644 --- a/listers/extensions/v1beta1/deployment_expansion.go +++ b/listers/extensions/v1beta1/deployment_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/extensions/v1beta1/ingress_expansion.go b/listers/extensions/v1beta1/ingress_expansion.go index 4f130cdf8..d81ed6bcc 100644 --- a/listers/extensions/v1beta1/ingress_expansion.go +++ b/listers/extensions/v1beta1/ingress_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/extensions/v1beta1/networkpolicy_expansion.go b/listers/extensions/v1beta1/networkpolicy_expansion.go index e9d5f4ec1..90d8ecb09 100644 --- a/listers/extensions/v1beta1/networkpolicy_expansion.go +++ b/listers/extensions/v1beta1/networkpolicy_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/flowcontrol/v1/flowschema_expansion.go b/listers/flowcontrol/v1/flowschema_expansion.go index daadff169..ea1bcff31 100644 --- a/listers/flowcontrol/v1/flowschema_expansion.go +++ b/listers/flowcontrol/v1/flowschema_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/flowcontrol/v1/prioritylevelconfiguration_expansion.go b/listers/flowcontrol/v1/prioritylevelconfiguration_expansion.go index cd43625e2..183d33c39 100644 --- a/listers/flowcontrol/v1/prioritylevelconfiguration_expansion.go +++ b/listers/flowcontrol/v1/prioritylevelconfiguration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/flowcontrol/v1beta1/flowschema_expansion.go b/listers/flowcontrol/v1beta1/flowschema_expansion.go index 14fe7ca39..707b36dc9 100644 --- a/listers/flowcontrol/v1beta1/flowschema_expansion.go +++ b/listers/flowcontrol/v1beta1/flowschema_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/flowcontrol/v1beta1/prioritylevelconfiguration_expansion.go b/listers/flowcontrol/v1beta1/prioritylevelconfiguration_expansion.go index 25ea6a230..8c57993bb 100644 --- a/listers/flowcontrol/v1beta1/prioritylevelconfiguration_expansion.go +++ b/listers/flowcontrol/v1beta1/prioritylevelconfiguration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/flowcontrol/v1beta2/flowschema_expansion.go b/listers/flowcontrol/v1beta2/flowschema_expansion.go index 002d1a0e1..f18fcb623 100644 --- a/listers/flowcontrol/v1beta2/flowschema_expansion.go +++ b/listers/flowcontrol/v1beta2/flowschema_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/flowcontrol/v1beta2/prioritylevelconfiguration_expansion.go b/listers/flowcontrol/v1beta2/prioritylevelconfiguration_expansion.go index 8fbfa4e13..b3501744e 100644 --- a/listers/flowcontrol/v1beta2/prioritylevelconfiguration_expansion.go +++ b/listers/flowcontrol/v1beta2/prioritylevelconfiguration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/flowcontrol/v1beta3/flowschema_expansion.go b/listers/flowcontrol/v1beta3/flowschema_expansion.go index e10efeabb..28d4c0d74 100644 --- a/listers/flowcontrol/v1beta3/flowschema_expansion.go +++ b/listers/flowcontrol/v1beta3/flowschema_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/flowcontrol/v1beta3/prioritylevelconfiguration_expansion.go b/listers/flowcontrol/v1beta3/prioritylevelconfiguration_expansion.go index dc4114b39..f4a6c9093 100644 --- a/listers/flowcontrol/v1beta3/prioritylevelconfiguration_expansion.go +++ b/listers/flowcontrol/v1beta3/prioritylevelconfiguration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1/ingress_expansion.go b/listers/networking/v1/ingress_expansion.go index a49d30393..358c6bbcb 100644 --- a/listers/networking/v1/ingress_expansion.go +++ b/listers/networking/v1/ingress_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1/ingressclass_expansion.go b/listers/networking/v1/ingressclass_expansion.go index bc79925f8..18ea025e7 100644 --- a/listers/networking/v1/ingressclass_expansion.go +++ b/listers/networking/v1/ingressclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1/networkpolicy_expansion.go b/listers/networking/v1/networkpolicy_expansion.go index 593162319..c2a0cf702 100644 --- a/listers/networking/v1/networkpolicy_expansion.go +++ b/listers/networking/v1/networkpolicy_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1alpha1/ipaddress_expansion.go b/listers/networking/v1alpha1/ipaddress_expansion.go index 6769ff5dd..c97c40707 100644 --- a/listers/networking/v1alpha1/ipaddress_expansion.go +++ b/listers/networking/v1alpha1/ipaddress_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1alpha1/servicecidr_expansion.go b/listers/networking/v1alpha1/servicecidr_expansion.go index 1c2513923..2d504c619 100644 --- a/listers/networking/v1alpha1/servicecidr_expansion.go +++ b/listers/networking/v1alpha1/servicecidr_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1beta1/ingress_expansion.go b/listers/networking/v1beta1/ingress_expansion.go index 4f130cdf8..d81ed6bcc 100644 --- a/listers/networking/v1beta1/ingress_expansion.go +++ b/listers/networking/v1beta1/ingress_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1beta1/ingressclass_expansion.go b/listers/networking/v1beta1/ingressclass_expansion.go index c0ab6ad6f..0ac483f43 100644 --- a/listers/networking/v1beta1/ingressclass_expansion.go +++ b/listers/networking/v1beta1/ingressclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1beta1/ipaddress_expansion.go b/listers/networking/v1beta1/ipaddress_expansion.go index c9fb25469..ad0016d09 100644 --- a/listers/networking/v1beta1/ipaddress_expansion.go +++ b/listers/networking/v1beta1/ipaddress_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/networking/v1beta1/servicecidr_expansion.go b/listers/networking/v1beta1/servicecidr_expansion.go index a5cfa0d4c..b14065b30 100644 --- a/listers/networking/v1beta1/servicecidr_expansion.go +++ b/listers/networking/v1beta1/servicecidr_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/node/v1/runtimeclass_expansion.go b/listers/node/v1/runtimeclass_expansion.go index dc580f2e8..119137cef 100644 --- a/listers/node/v1/runtimeclass_expansion.go +++ b/listers/node/v1/runtimeclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/node/v1alpha1/runtimeclass_expansion.go b/listers/node/v1alpha1/runtimeclass_expansion.go index 50f1bc0f8..b325c0850 100644 --- a/listers/node/v1alpha1/runtimeclass_expansion.go +++ b/listers/node/v1alpha1/runtimeclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/node/v1beta1/runtimeclass_expansion.go b/listers/node/v1beta1/runtimeclass_expansion.go index c4617b616..de6dea995 100644 --- a/listers/node/v1beta1/runtimeclass_expansion.go +++ b/listers/node/v1beta1/runtimeclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1/clusterrole_expansion.go b/listers/rbac/v1/clusterrole_expansion.go index bd22d482a..5a2da830b 100644 --- a/listers/rbac/v1/clusterrole_expansion.go +++ b/listers/rbac/v1/clusterrole_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1/clusterrolebinding_expansion.go b/listers/rbac/v1/clusterrolebinding_expansion.go index 7a1db9139..3a95b4d11 100644 --- a/listers/rbac/v1/clusterrolebinding_expansion.go +++ b/listers/rbac/v1/clusterrolebinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1/role_expansion.go b/listers/rbac/v1/role_expansion.go index c1c0e9d5b..6175fd52e 100644 --- a/listers/rbac/v1/role_expansion.go +++ b/listers/rbac/v1/role_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1/rolebinding_expansion.go b/listers/rbac/v1/rolebinding_expansion.go index 84d93c840..480753a98 100644 --- a/listers/rbac/v1/rolebinding_expansion.go +++ b/listers/rbac/v1/rolebinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1alpha1/clusterrole_expansion.go b/listers/rbac/v1alpha1/clusterrole_expansion.go index 9bcbe1e43..26b2940b4 100644 --- a/listers/rbac/v1alpha1/clusterrole_expansion.go +++ b/listers/rbac/v1alpha1/clusterrole_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1alpha1/clusterrolebinding_expansion.go b/listers/rbac/v1alpha1/clusterrolebinding_expansion.go index 6f1748539..0f6d21e61 100644 --- a/listers/rbac/v1alpha1/clusterrolebinding_expansion.go +++ b/listers/rbac/v1alpha1/clusterrolebinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1alpha1/role_expansion.go b/listers/rbac/v1alpha1/role_expansion.go index 178b21fc8..f84ead668 100644 --- a/listers/rbac/v1alpha1/role_expansion.go +++ b/listers/rbac/v1alpha1/role_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1alpha1/rolebinding_expansion.go b/listers/rbac/v1alpha1/rolebinding_expansion.go index 3b62f279b..723cf9224 100644 --- a/listers/rbac/v1alpha1/rolebinding_expansion.go +++ b/listers/rbac/v1alpha1/rolebinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1beta1/clusterrole_expansion.go b/listers/rbac/v1beta1/clusterrole_expansion.go index 327e32253..c39dd4f1d 100644 --- a/listers/rbac/v1beta1/clusterrole_expansion.go +++ b/listers/rbac/v1beta1/clusterrole_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1beta1/clusterrolebinding_expansion.go b/listers/rbac/v1beta1/clusterrolebinding_expansion.go index 19d0054a7..610e39d06 100644 --- a/listers/rbac/v1beta1/clusterrolebinding_expansion.go +++ b/listers/rbac/v1beta1/clusterrolebinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1beta1/role_expansion.go b/listers/rbac/v1beta1/role_expansion.go index 4084bb8a6..f6520eaf8 100644 --- a/listers/rbac/v1beta1/role_expansion.go +++ b/listers/rbac/v1beta1/role_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/rbac/v1beta1/rolebinding_expansion.go b/listers/rbac/v1beta1/rolebinding_expansion.go index deeabe7f3..6b9499d23 100644 --- a/listers/rbac/v1beta1/rolebinding_expansion.go +++ b/listers/rbac/v1beta1/rolebinding_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/resource/v1alpha3/deviceclass_expansion.go b/listers/resource/v1alpha3/deviceclass_expansion.go index e33928e0a..366780cf9 100644 --- a/listers/resource/v1alpha3/deviceclass_expansion.go +++ b/listers/resource/v1alpha3/deviceclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/resource/v1alpha3/podschedulingcontext.go b/listers/resource/v1alpha3/podschedulingcontext.go new file mode 100644 index 000000000..20cadbcc2 --- /dev/null +++ b/listers/resource/v1alpha3/podschedulingcontext.go @@ -0,0 +1,115 @@ +/* +Copyright The KCP 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 kcp code-generator. DO NOT EDIT. + +package v1alpha3 + +import ( + kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" + "github.com/kcp-dev/logicalcluster/v3" + + resourcev1alpha3 "k8s.io/api/resource/v1alpha3" + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/labels" + resourcev1alpha3listers "k8s.io/client-go/listers/resource/v1alpha3" + "k8s.io/client-go/tools/cache" +) + +// PodSchedulingContextClusterLister can list PodSchedulingContexts across all workspaces, or scope down to a PodSchedulingContextLister for one workspace. +// All objects returned here must be treated as read-only. +type PodSchedulingContextClusterLister interface { + // List lists all PodSchedulingContexts in the indexer. + // Objects returned here must be treated as read-only. + List(selector labels.Selector) (ret []*resourcev1alpha3.PodSchedulingContext, err error) + // Cluster returns a lister that can list and get PodSchedulingContexts in one workspace. + Cluster(clusterName logicalcluster.Name) resourcev1alpha3listers.PodSchedulingContextLister + PodSchedulingContextClusterListerExpansion +} + +type podSchedulingContextClusterLister struct { + indexer cache.Indexer +} + +// NewPodSchedulingContextClusterLister returns a new PodSchedulingContextClusterLister. +// We assume that the indexer: +// - is fed by a cross-workspace LIST+WATCH +// - uses kcpcache.MetaClusterNamespaceKeyFunc as the key function +// - has the kcpcache.ClusterIndex as an index +// - has the kcpcache.ClusterAndNamespaceIndex as an index +func NewPodSchedulingContextClusterLister(indexer cache.Indexer) *podSchedulingContextClusterLister { + return &podSchedulingContextClusterLister{indexer: indexer} +} + +// List lists all PodSchedulingContexts in the indexer across all workspaces. +func (s *podSchedulingContextClusterLister) List(selector labels.Selector) (ret []*resourcev1alpha3.PodSchedulingContext, err error) { + err = cache.ListAll(s.indexer, selector, func(m interface{}) { + ret = append(ret, m.(*resourcev1alpha3.PodSchedulingContext)) + }) + return ret, err +} + +// Cluster scopes the lister to one workspace, allowing users to list and get PodSchedulingContexts. +func (s *podSchedulingContextClusterLister) Cluster(clusterName logicalcluster.Name) resourcev1alpha3listers.PodSchedulingContextLister { + return &podSchedulingContextLister{indexer: s.indexer, clusterName: clusterName} +} + +// podSchedulingContextLister implements the resourcev1alpha3listers.PodSchedulingContextLister interface. +type podSchedulingContextLister struct { + indexer cache.Indexer + clusterName logicalcluster.Name +} + +// List lists all PodSchedulingContexts in the indexer for a workspace. +func (s *podSchedulingContextLister) List(selector labels.Selector) (ret []*resourcev1alpha3.PodSchedulingContext, err error) { + err = kcpcache.ListAllByCluster(s.indexer, s.clusterName, selector, func(i interface{}) { + ret = append(ret, i.(*resourcev1alpha3.PodSchedulingContext)) + }) + return ret, err +} + +// PodSchedulingContexts returns an object that can list and get PodSchedulingContexts in one namespace. +func (s *podSchedulingContextLister) PodSchedulingContexts(namespace string) resourcev1alpha3listers.PodSchedulingContextNamespaceLister { + return &podSchedulingContextNamespaceLister{indexer: s.indexer, clusterName: s.clusterName, namespace: namespace} +} + +// podSchedulingContextNamespaceLister implements the resourcev1alpha3listers.PodSchedulingContextNamespaceLister interface. +type podSchedulingContextNamespaceLister struct { + indexer cache.Indexer + clusterName logicalcluster.Name + namespace string +} + +// List lists all PodSchedulingContexts in the indexer for a given workspace and namespace. +func (s *podSchedulingContextNamespaceLister) List(selector labels.Selector) (ret []*resourcev1alpha3.PodSchedulingContext, err error) { + err = kcpcache.ListAllByClusterAndNamespace(s.indexer, s.clusterName, s.namespace, selector, func(i interface{}) { + ret = append(ret, i.(*resourcev1alpha3.PodSchedulingContext)) + }) + return ret, err +} + +// Get retrieves the PodSchedulingContext from the indexer for a given workspace, namespace and name. +func (s *podSchedulingContextNamespaceLister) Get(name string) (*resourcev1alpha3.PodSchedulingContext, error) { + key := kcpcache.ToClusterAwareKey(s.clusterName.String(), s.namespace, name) + obj, exists, err := s.indexer.GetByKey(key) + if err != nil { + return nil, err + } + if !exists { + return nil, errors.NewNotFound(resourcev1alpha3.Resource("podschedulingcontexts"), name) + } + return obj.(*resourcev1alpha3.PodSchedulingContext), nil +} diff --git a/listers/resource/v1beta1/resourceslice_expansion.go b/listers/resource/v1alpha3/podschedulingcontext_expansion.go similarity index 75% rename from listers/resource/v1beta1/resourceslice_expansion.go rename to listers/resource/v1alpha3/podschedulingcontext_expansion.go index f0b1fd962..3d2df6ec2 100644 --- a/listers/resource/v1beta1/resourceslice_expansion.go +++ b/listers/resource/v1alpha3/podschedulingcontext_expansion.go @@ -16,7 +16,7 @@ limitations under the License. // Code generated by kcp code-generator. DO NOT EDIT. -package v1beta1 +package v1alpha3 -// ResourceSliceClusterListerExpansion allows custom methods to be added to ResourceSliceClusterLister. -type ResourceSliceClusterListerExpansion interface{} +// PodSchedulingContextClusterListerExpansion allows custom methods to be added to PodSchedulingContextClusterLister. +type PodSchedulingContextClusterListerExpansion interface{} diff --git a/listers/resource/v1alpha3/resourceclaim_expansion.go b/listers/resource/v1alpha3/resourceclaim_expansion.go index f942069fb..28141932b 100644 --- a/listers/resource/v1alpha3/resourceclaim_expansion.go +++ b/listers/resource/v1alpha3/resourceclaim_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/resource/v1alpha3/resourceclaimtemplate_expansion.go b/listers/resource/v1alpha3/resourceclaimtemplate_expansion.go index 757ee62b6..646543e51 100644 --- a/listers/resource/v1alpha3/resourceclaimtemplate_expansion.go +++ b/listers/resource/v1alpha3/resourceclaimtemplate_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/resource/v1alpha3/resourceslice_expansion.go b/listers/resource/v1alpha3/resourceslice_expansion.go index 9ddaf8ca3..54c0b83d1 100644 --- a/listers/resource/v1alpha3/resourceslice_expansion.go +++ b/listers/resource/v1alpha3/resourceslice_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/resource/v1beta1/deviceclass.go b/listers/resource/v1beta1/deviceclass.go deleted file mode 100644 index abe11f03a..000000000 --- a/listers/resource/v1beta1/deviceclass.go +++ /dev/null @@ -1,94 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/labels" - resourcev1beta1listers "k8s.io/client-go/listers/resource/v1beta1" - "k8s.io/client-go/tools/cache" -) - -// DeviceClassClusterLister can list DeviceClasses across all workspaces, or scope down to a DeviceClassLister for one workspace. -// All objects returned here must be treated as read-only. -type DeviceClassClusterLister interface { - // List lists all DeviceClasses in the indexer. - // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*resourcev1beta1.DeviceClass, err error) - // Cluster returns a lister that can list and get DeviceClasses in one workspace. - Cluster(clusterName logicalcluster.Name) resourcev1beta1listers.DeviceClassLister - DeviceClassClusterListerExpansion -} - -type deviceClassClusterLister struct { - indexer cache.Indexer -} - -// NewDeviceClassClusterLister returns a new DeviceClassClusterLister. -// We assume that the indexer: -// - is fed by a cross-workspace LIST+WATCH -// - uses kcpcache.MetaClusterNamespaceKeyFunc as the key function -// - has the kcpcache.ClusterIndex as an index -func NewDeviceClassClusterLister(indexer cache.Indexer) *deviceClassClusterLister { - return &deviceClassClusterLister{indexer: indexer} -} - -// List lists all DeviceClasses in the indexer across all workspaces. -func (s *deviceClassClusterLister) List(selector labels.Selector) (ret []*resourcev1beta1.DeviceClass, err error) { - err = cache.ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*resourcev1beta1.DeviceClass)) - }) - return ret, err -} - -// Cluster scopes the lister to one workspace, allowing users to list and get DeviceClasses. -func (s *deviceClassClusterLister) Cluster(clusterName logicalcluster.Name) resourcev1beta1listers.DeviceClassLister { - return &deviceClassLister{indexer: s.indexer, clusterName: clusterName} -} - -// deviceClassLister implements the resourcev1beta1listers.DeviceClassLister interface. -type deviceClassLister struct { - indexer cache.Indexer - clusterName logicalcluster.Name -} - -// List lists all DeviceClasses in the indexer for a workspace. -func (s *deviceClassLister) List(selector labels.Selector) (ret []*resourcev1beta1.DeviceClass, err error) { - err = kcpcache.ListAllByCluster(s.indexer, s.clusterName, selector, func(i interface{}) { - ret = append(ret, i.(*resourcev1beta1.DeviceClass)) - }) - return ret, err -} - -// Get retrieves the DeviceClass from the indexer for a given workspace and name. -func (s *deviceClassLister) Get(name string) (*resourcev1beta1.DeviceClass, error) { - key := kcpcache.ToClusterAwareKey(s.clusterName.String(), "", name) - obj, exists, err := s.indexer.GetByKey(key) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(resourcev1beta1.Resource("deviceclasses"), name) - } - return obj.(*resourcev1beta1.DeviceClass), nil -} diff --git a/listers/resource/v1beta1/deviceclass_expansion.go b/listers/resource/v1beta1/deviceclass_expansion.go deleted file mode 100644 index 372f52e99..000000000 --- a/listers/resource/v1beta1/deviceclass_expansion.go +++ /dev/null @@ -1,22 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -// DeviceClassClusterListerExpansion allows custom methods to be added to DeviceClassClusterLister. -type DeviceClassClusterListerExpansion interface{} diff --git a/listers/resource/v1beta1/resourceclaim.go b/listers/resource/v1beta1/resourceclaim.go deleted file mode 100644 index c86f56e0b..000000000 --- a/listers/resource/v1beta1/resourceclaim.go +++ /dev/null @@ -1,115 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/labels" - resourcev1beta1listers "k8s.io/client-go/listers/resource/v1beta1" - "k8s.io/client-go/tools/cache" -) - -// ResourceClaimClusterLister can list ResourceClaims across all workspaces, or scope down to a ResourceClaimLister for one workspace. -// All objects returned here must be treated as read-only. -type ResourceClaimClusterLister interface { - // List lists all ResourceClaims in the indexer. - // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*resourcev1beta1.ResourceClaim, err error) - // Cluster returns a lister that can list and get ResourceClaims in one workspace. - Cluster(clusterName logicalcluster.Name) resourcev1beta1listers.ResourceClaimLister - ResourceClaimClusterListerExpansion -} - -type resourceClaimClusterLister struct { - indexer cache.Indexer -} - -// NewResourceClaimClusterLister returns a new ResourceClaimClusterLister. -// We assume that the indexer: -// - is fed by a cross-workspace LIST+WATCH -// - uses kcpcache.MetaClusterNamespaceKeyFunc as the key function -// - has the kcpcache.ClusterIndex as an index -// - has the kcpcache.ClusterAndNamespaceIndex as an index -func NewResourceClaimClusterLister(indexer cache.Indexer) *resourceClaimClusterLister { - return &resourceClaimClusterLister{indexer: indexer} -} - -// List lists all ResourceClaims in the indexer across all workspaces. -func (s *resourceClaimClusterLister) List(selector labels.Selector) (ret []*resourcev1beta1.ResourceClaim, err error) { - err = cache.ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*resourcev1beta1.ResourceClaim)) - }) - return ret, err -} - -// Cluster scopes the lister to one workspace, allowing users to list and get ResourceClaims. -func (s *resourceClaimClusterLister) Cluster(clusterName logicalcluster.Name) resourcev1beta1listers.ResourceClaimLister { - return &resourceClaimLister{indexer: s.indexer, clusterName: clusterName} -} - -// resourceClaimLister implements the resourcev1beta1listers.ResourceClaimLister interface. -type resourceClaimLister struct { - indexer cache.Indexer - clusterName logicalcluster.Name -} - -// List lists all ResourceClaims in the indexer for a workspace. -func (s *resourceClaimLister) List(selector labels.Selector) (ret []*resourcev1beta1.ResourceClaim, err error) { - err = kcpcache.ListAllByCluster(s.indexer, s.clusterName, selector, func(i interface{}) { - ret = append(ret, i.(*resourcev1beta1.ResourceClaim)) - }) - return ret, err -} - -// ResourceClaims returns an object that can list and get ResourceClaims in one namespace. -func (s *resourceClaimLister) ResourceClaims(namespace string) resourcev1beta1listers.ResourceClaimNamespaceLister { - return &resourceClaimNamespaceLister{indexer: s.indexer, clusterName: s.clusterName, namespace: namespace} -} - -// resourceClaimNamespaceLister implements the resourcev1beta1listers.ResourceClaimNamespaceLister interface. -type resourceClaimNamespaceLister struct { - indexer cache.Indexer - clusterName logicalcluster.Name - namespace string -} - -// List lists all ResourceClaims in the indexer for a given workspace and namespace. -func (s *resourceClaimNamespaceLister) List(selector labels.Selector) (ret []*resourcev1beta1.ResourceClaim, err error) { - err = kcpcache.ListAllByClusterAndNamespace(s.indexer, s.clusterName, s.namespace, selector, func(i interface{}) { - ret = append(ret, i.(*resourcev1beta1.ResourceClaim)) - }) - return ret, err -} - -// Get retrieves the ResourceClaim from the indexer for a given workspace, namespace and name. -func (s *resourceClaimNamespaceLister) Get(name string) (*resourcev1beta1.ResourceClaim, error) { - key := kcpcache.ToClusterAwareKey(s.clusterName.String(), s.namespace, name) - obj, exists, err := s.indexer.GetByKey(key) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(resourcev1beta1.Resource("resourceclaims"), name) - } - return obj.(*resourcev1beta1.ResourceClaim), nil -} diff --git a/listers/resource/v1beta1/resourceclaim_expansion.go b/listers/resource/v1beta1/resourceclaim_expansion.go deleted file mode 100644 index 7a1649e1b..000000000 --- a/listers/resource/v1beta1/resourceclaim_expansion.go +++ /dev/null @@ -1,22 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -// ResourceClaimClusterListerExpansion allows custom methods to be added to ResourceClaimClusterLister. -type ResourceClaimClusterListerExpansion interface{} diff --git a/listers/resource/v1beta1/resourceclaimtemplate.go b/listers/resource/v1beta1/resourceclaimtemplate.go deleted file mode 100644 index ef54878cd..000000000 --- a/listers/resource/v1beta1/resourceclaimtemplate.go +++ /dev/null @@ -1,115 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/labels" - resourcev1beta1listers "k8s.io/client-go/listers/resource/v1beta1" - "k8s.io/client-go/tools/cache" -) - -// ResourceClaimTemplateClusterLister can list ResourceClaimTemplates across all workspaces, or scope down to a ResourceClaimTemplateLister for one workspace. -// All objects returned here must be treated as read-only. -type ResourceClaimTemplateClusterLister interface { - // List lists all ResourceClaimTemplates in the indexer. - // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*resourcev1beta1.ResourceClaimTemplate, err error) - // Cluster returns a lister that can list and get ResourceClaimTemplates in one workspace. - Cluster(clusterName logicalcluster.Name) resourcev1beta1listers.ResourceClaimTemplateLister - ResourceClaimTemplateClusterListerExpansion -} - -type resourceClaimTemplateClusterLister struct { - indexer cache.Indexer -} - -// NewResourceClaimTemplateClusterLister returns a new ResourceClaimTemplateClusterLister. -// We assume that the indexer: -// - is fed by a cross-workspace LIST+WATCH -// - uses kcpcache.MetaClusterNamespaceKeyFunc as the key function -// - has the kcpcache.ClusterIndex as an index -// - has the kcpcache.ClusterAndNamespaceIndex as an index -func NewResourceClaimTemplateClusterLister(indexer cache.Indexer) *resourceClaimTemplateClusterLister { - return &resourceClaimTemplateClusterLister{indexer: indexer} -} - -// List lists all ResourceClaimTemplates in the indexer across all workspaces. -func (s *resourceClaimTemplateClusterLister) List(selector labels.Selector) (ret []*resourcev1beta1.ResourceClaimTemplate, err error) { - err = cache.ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*resourcev1beta1.ResourceClaimTemplate)) - }) - return ret, err -} - -// Cluster scopes the lister to one workspace, allowing users to list and get ResourceClaimTemplates. -func (s *resourceClaimTemplateClusterLister) Cluster(clusterName logicalcluster.Name) resourcev1beta1listers.ResourceClaimTemplateLister { - return &resourceClaimTemplateLister{indexer: s.indexer, clusterName: clusterName} -} - -// resourceClaimTemplateLister implements the resourcev1beta1listers.ResourceClaimTemplateLister interface. -type resourceClaimTemplateLister struct { - indexer cache.Indexer - clusterName logicalcluster.Name -} - -// List lists all ResourceClaimTemplates in the indexer for a workspace. -func (s *resourceClaimTemplateLister) List(selector labels.Selector) (ret []*resourcev1beta1.ResourceClaimTemplate, err error) { - err = kcpcache.ListAllByCluster(s.indexer, s.clusterName, selector, func(i interface{}) { - ret = append(ret, i.(*resourcev1beta1.ResourceClaimTemplate)) - }) - return ret, err -} - -// ResourceClaimTemplates returns an object that can list and get ResourceClaimTemplates in one namespace. -func (s *resourceClaimTemplateLister) ResourceClaimTemplates(namespace string) resourcev1beta1listers.ResourceClaimTemplateNamespaceLister { - return &resourceClaimTemplateNamespaceLister{indexer: s.indexer, clusterName: s.clusterName, namespace: namespace} -} - -// resourceClaimTemplateNamespaceLister implements the resourcev1beta1listers.ResourceClaimTemplateNamespaceLister interface. -type resourceClaimTemplateNamespaceLister struct { - indexer cache.Indexer - clusterName logicalcluster.Name - namespace string -} - -// List lists all ResourceClaimTemplates in the indexer for a given workspace and namespace. -func (s *resourceClaimTemplateNamespaceLister) List(selector labels.Selector) (ret []*resourcev1beta1.ResourceClaimTemplate, err error) { - err = kcpcache.ListAllByClusterAndNamespace(s.indexer, s.clusterName, s.namespace, selector, func(i interface{}) { - ret = append(ret, i.(*resourcev1beta1.ResourceClaimTemplate)) - }) - return ret, err -} - -// Get retrieves the ResourceClaimTemplate from the indexer for a given workspace, namespace and name. -func (s *resourceClaimTemplateNamespaceLister) Get(name string) (*resourcev1beta1.ResourceClaimTemplate, error) { - key := kcpcache.ToClusterAwareKey(s.clusterName.String(), s.namespace, name) - obj, exists, err := s.indexer.GetByKey(key) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(resourcev1beta1.Resource("resourceclaimtemplates"), name) - } - return obj.(*resourcev1beta1.ResourceClaimTemplate), nil -} diff --git a/listers/resource/v1beta1/resourceclaimtemplate_expansion.go b/listers/resource/v1beta1/resourceclaimtemplate_expansion.go deleted file mode 100644 index 6ae346cae..000000000 --- a/listers/resource/v1beta1/resourceclaimtemplate_expansion.go +++ /dev/null @@ -1,22 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -// ResourceClaimTemplateClusterListerExpansion allows custom methods to be added to ResourceClaimTemplateClusterLister. -type ResourceClaimTemplateClusterListerExpansion interface{} diff --git a/listers/resource/v1beta1/resourceslice.go b/listers/resource/v1beta1/resourceslice.go deleted file mode 100644 index cc0870317..000000000 --- a/listers/resource/v1beta1/resourceslice.go +++ /dev/null @@ -1,94 +0,0 @@ -/* -Copyright The KCP 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 kcp code-generator. DO NOT EDIT. - -package v1beta1 - -import ( - kcpcache "github.com/kcp-dev/apimachinery/v2/pkg/cache" - "github.com/kcp-dev/logicalcluster/v3" - - resourcev1beta1 "k8s.io/api/resource/v1beta1" - "k8s.io/apimachinery/pkg/api/errors" - "k8s.io/apimachinery/pkg/labels" - resourcev1beta1listers "k8s.io/client-go/listers/resource/v1beta1" - "k8s.io/client-go/tools/cache" -) - -// ResourceSliceClusterLister can list ResourceSlices across all workspaces, or scope down to a ResourceSliceLister for one workspace. -// All objects returned here must be treated as read-only. -type ResourceSliceClusterLister interface { - // List lists all ResourceSlices in the indexer. - // Objects returned here must be treated as read-only. - List(selector labels.Selector) (ret []*resourcev1beta1.ResourceSlice, err error) - // Cluster returns a lister that can list and get ResourceSlices in one workspace. - Cluster(clusterName logicalcluster.Name) resourcev1beta1listers.ResourceSliceLister - ResourceSliceClusterListerExpansion -} - -type resourceSliceClusterLister struct { - indexer cache.Indexer -} - -// NewResourceSliceClusterLister returns a new ResourceSliceClusterLister. -// We assume that the indexer: -// - is fed by a cross-workspace LIST+WATCH -// - uses kcpcache.MetaClusterNamespaceKeyFunc as the key function -// - has the kcpcache.ClusterIndex as an index -func NewResourceSliceClusterLister(indexer cache.Indexer) *resourceSliceClusterLister { - return &resourceSliceClusterLister{indexer: indexer} -} - -// List lists all ResourceSlices in the indexer across all workspaces. -func (s *resourceSliceClusterLister) List(selector labels.Selector) (ret []*resourcev1beta1.ResourceSlice, err error) { - err = cache.ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*resourcev1beta1.ResourceSlice)) - }) - return ret, err -} - -// Cluster scopes the lister to one workspace, allowing users to list and get ResourceSlices. -func (s *resourceSliceClusterLister) Cluster(clusterName logicalcluster.Name) resourcev1beta1listers.ResourceSliceLister { - return &resourceSliceLister{indexer: s.indexer, clusterName: clusterName} -} - -// resourceSliceLister implements the resourcev1beta1listers.ResourceSliceLister interface. -type resourceSliceLister struct { - indexer cache.Indexer - clusterName logicalcluster.Name -} - -// List lists all ResourceSlices in the indexer for a workspace. -func (s *resourceSliceLister) List(selector labels.Selector) (ret []*resourcev1beta1.ResourceSlice, err error) { - err = kcpcache.ListAllByCluster(s.indexer, s.clusterName, selector, func(i interface{}) { - ret = append(ret, i.(*resourcev1beta1.ResourceSlice)) - }) - return ret, err -} - -// Get retrieves the ResourceSlice from the indexer for a given workspace and name. -func (s *resourceSliceLister) Get(name string) (*resourcev1beta1.ResourceSlice, error) { - key := kcpcache.ToClusterAwareKey(s.clusterName.String(), "", name) - obj, exists, err := s.indexer.GetByKey(key) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(resourcev1beta1.Resource("resourceslices"), name) - } - return obj.(*resourcev1beta1.ResourceSlice), nil -} diff --git a/listers/scheduling/v1/priorityclass_expansion.go b/listers/scheduling/v1/priorityclass_expansion.go index f4fa35e7d..aae4d68c6 100644 --- a/listers/scheduling/v1/priorityclass_expansion.go +++ b/listers/scheduling/v1/priorityclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/scheduling/v1alpha1/priorityclass_expansion.go b/listers/scheduling/v1alpha1/priorityclass_expansion.go index 5306a9f39..5cd814dec 100644 --- a/listers/scheduling/v1alpha1/priorityclass_expansion.go +++ b/listers/scheduling/v1alpha1/priorityclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/scheduling/v1beta1/priorityclass_expansion.go b/listers/scheduling/v1beta1/priorityclass_expansion.go index 934611db6..a4222853e 100644 --- a/listers/scheduling/v1beta1/priorityclass_expansion.go +++ b/listers/scheduling/v1beta1/priorityclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1/csidriver_expansion.go b/listers/storage/v1/csidriver_expansion.go index cf198daf0..4ccefa009 100644 --- a/listers/storage/v1/csidriver_expansion.go +++ b/listers/storage/v1/csidriver_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1/csinode_expansion.go b/listers/storage/v1/csinode_expansion.go index 1d0fc861a..7071e2a88 100644 --- a/listers/storage/v1/csinode_expansion.go +++ b/listers/storage/v1/csinode_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1/csistoragecapacity_expansion.go b/listers/storage/v1/csistoragecapacity_expansion.go index f12e835eb..68afd44ad 100644 --- a/listers/storage/v1/csistoragecapacity_expansion.go +++ b/listers/storage/v1/csistoragecapacity_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1/storageclass_expansion.go b/listers/storage/v1/storageclass_expansion.go index 2d8414c1a..736fc4442 100644 --- a/listers/storage/v1/storageclass_expansion.go +++ b/listers/storage/v1/storageclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1/volumeattachment_expansion.go b/listers/storage/v1/volumeattachment_expansion.go index 50f9b263f..26f5ae008 100644 --- a/listers/storage/v1/volumeattachment_expansion.go +++ b/listers/storage/v1/volumeattachment_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1alpha1/csistoragecapacity_expansion.go b/listers/storage/v1alpha1/csistoragecapacity_expansion.go index 44d25078f..bc76f6e4b 100644 --- a/listers/storage/v1alpha1/csistoragecapacity_expansion.go +++ b/listers/storage/v1alpha1/csistoragecapacity_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1alpha1/volumeattachment_expansion.go b/listers/storage/v1alpha1/volumeattachment_expansion.go index b91ad6142..15c559246 100644 --- a/listers/storage/v1alpha1/volumeattachment_expansion.go +++ b/listers/storage/v1alpha1/volumeattachment_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1alpha1/volumeattributesclass_expansion.go b/listers/storage/v1alpha1/volumeattributesclass_expansion.go index 5d3e3113b..8feb26f2c 100644 --- a/listers/storage/v1alpha1/volumeattributesclass_expansion.go +++ b/listers/storage/v1alpha1/volumeattributesclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1beta1/csidriver_expansion.go b/listers/storage/v1beta1/csidriver_expansion.go index 228c7b274..858f59289 100644 --- a/listers/storage/v1beta1/csidriver_expansion.go +++ b/listers/storage/v1beta1/csidriver_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1beta1/csinode_expansion.go b/listers/storage/v1beta1/csinode_expansion.go index 97e83410a..c5f4e4bbf 100644 --- a/listers/storage/v1beta1/csinode_expansion.go +++ b/listers/storage/v1beta1/csinode_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1beta1/csistoragecapacity_expansion.go b/listers/storage/v1beta1/csistoragecapacity_expansion.go index 82fc7075a..2695d3fdc 100644 --- a/listers/storage/v1beta1/csistoragecapacity_expansion.go +++ b/listers/storage/v1beta1/csistoragecapacity_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1beta1/storageclass_expansion.go b/listers/storage/v1beta1/storageclass_expansion.go index 9ab464b00..07e942a18 100644 --- a/listers/storage/v1beta1/storageclass_expansion.go +++ b/listers/storage/v1beta1/storageclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1beta1/volumeattachment_expansion.go b/listers/storage/v1beta1/volumeattachment_expansion.go index f0bac78ba..f4d8d8d8f 100644 --- a/listers/storage/v1beta1/volumeattachment_expansion.go +++ b/listers/storage/v1beta1/volumeattachment_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storage/v1beta1/volumeattributesclass_expansion.go b/listers/storage/v1beta1/volumeattributesclass_expansion.go index c3352780a..31d9126f5 100644 --- a/listers/storage/v1beta1/volumeattributesclass_expansion.go +++ b/listers/storage/v1beta1/volumeattributesclass_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors. diff --git a/listers/storagemigration/v1alpha1/storageversionmigration_expansion.go b/listers/storagemigration/v1alpha1/storageversionmigration_expansion.go index dbd4b6c1b..11468190f 100644 --- a/listers/storagemigration/v1alpha1/storageversionmigration_expansion.go +++ b/listers/storagemigration/v1alpha1/storageversionmigration_expansion.go @@ -1,6 +1,3 @@ -//go:build !ignore_autogenerated -// +build !ignore_autogenerated - /* Copyright The KCP Authors.