From 6ad34c29b3eb6f3d045bcb496ad8a8d6e9296106 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 12 Dec 2024 07:44:48 +0000 Subject: [PATCH 1/3] Bump k8s.io/code-generator from 0.31.2 to 0.32.0 in /tools Bumps [k8s.io/code-generator](https://github.com/kubernetes/code-generator) from 0.31.2 to 0.32.0. - [Commits](https://github.com/kubernetes/code-generator/compare/v0.31.2...v0.32.0) --- updated-dependencies: - dependency-name: k8s.io/code-generator dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- tools/go.mod | 21 ++++++++++----------- tools/go.sum | 44 ++++++++++++++++++++++---------------------- 2 files changed, 32 insertions(+), 33 deletions(-) diff --git a/tools/go.mod b/tools/go.mod index bf6e6ece1..61fae30df 100644 --- a/tools/go.mod +++ b/tools/go.mod @@ -1,11 +1,10 @@ module github.com/NVIDIA/gpu-operator/tools go 1.22.7 - toolchain go1.23.2 require ( - k8s.io/code-generator v0.31.2 + k8s.io/code-generator v0.32.0 sigs.k8s.io/controller-tools v0.16.5 sigs.k8s.io/kustomize/kustomize/v5 v5.5.0 ) @@ -17,9 +16,9 @@ require ( github.com/fxamacker/cbor/v2 v2.7.0 // indirect github.com/go-errors/errors v1.4.2 // indirect github.com/go-logr/logr v1.4.2 // indirect - github.com/go-openapi/jsonpointer v0.19.6 // indirect + github.com/go-openapi/jsonpointer v0.21.0 // indirect github.com/go-openapi/jsonreference v0.20.2 // indirect - github.com/go-openapi/swag v0.22.4 // indirect + github.com/go-openapi/swag v0.23.0 // indirect github.com/gobuffalo/flect v1.0.3 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/protobuf v1.5.4 // indirect @@ -47,22 +46,22 @@ require ( golang.org/x/sys v0.26.0 // indirect golang.org/x/text v0.19.0 // indirect golang.org/x/tools v0.26.0 // indirect - google.golang.org/protobuf v1.34.2 // indirect + google.golang.org/protobuf v1.35.1 // 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/api v0.31.2 // indirect k8s.io/apiextensions-apiserver v0.31.2 // indirect - k8s.io/apimachinery v0.31.2 // indirect - k8s.io/gengo/v2 v2.0.0-20240228010128-51d4e06bde70 // indirect + k8s.io/apimachinery v0.32.0 // indirect + k8s.io/gengo/v2 v2.0.0-20240911193312-2b36238f13e9 // indirect k8s.io/klog/v2 v2.130.1 // indirect - k8s.io/kube-openapi v0.0.0-20240228011516-70dd3763d340 // indirect - k8s.io/utils v0.0.0-20240711033017-18e509b52bc8 // indirect - sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect + k8s.io/kube-openapi v0.0.0-20241105132330-32ad38e42d3f // indirect + k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 // indirect + sigs.k8s.io/json v0.0.0-20241010143419-9aa6b5e7a4b3 // indirect sigs.k8s.io/kustomize/api v0.18.0 // indirect sigs.k8s.io/kustomize/cmd/config v0.15.0 // indirect sigs.k8s.io/kustomize/kyaml v0.18.1 // indirect - sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect + sigs.k8s.io/structured-merge-diff/v4 v4.4.2 // indirect sigs.k8s.io/yaml v1.4.0 // indirect ) diff --git a/tools/go.sum b/tools/go.sum index 6e947638e..6e321d745 100644 --- a/tools/go.sum +++ b/tools/go.sum @@ -16,13 +16,14 @@ github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxI github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= 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-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/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.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-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/gobuffalo/flect v1.0.3 h1:xeWBM2nui+qnVvNM4S3foBhCAL2XgPU+a7FdpelbTq4= github.com/gobuffalo/flect v1.0.3/go.mod h1:A5msMlrHtLqh9umBSnvabjsMrCcCpAyzglnDvkbYKHs= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= @@ -73,8 +74,8 @@ github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= github.com/onsi/ginkgo v1.16.5/go.mod h1:+E8gABHa3K6zRBolWtd+ROzc/U5bkGt0FwiG042wbpU= -github.com/onsi/gomega v1.34.2 h1:pNCwDkzrsv7MS9kpaQvVb1aVLahQXyJ/Tv5oAZMI3i8= -github.com/onsi/gomega v1.34.2/go.mod h1:v1xfxRgk0KIsG+QOdm7p8UosrOzPYRo60fd3B/1Dukc= +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/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= @@ -149,8 +150,8 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T 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/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= -google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= +google.golang.org/protobuf v1.35.1 h1:m3LfL6/Ca+fqnjnlqQXNpFPABW1UD7mjh8KO2mKFytA= +google.golang.org/protobuf v1.35.1/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= @@ -163,7 +164,6 @@ gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkep gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/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= @@ -173,22 +173,22 @@ k8s.io/api v0.31.2 h1:3wLBbL5Uom/8Zy98GRPXpJ254nEFpl+hwndmk9RwmL0= k8s.io/api v0.31.2/go.mod h1:bWmGvrGPssSK1ljmLzd3pwCQ9MgoTsRCuK35u6SygUk= k8s.io/apiextensions-apiserver v0.31.2 h1:W8EwUb8+WXBLu56ser5IudT2cOho0gAKeTOnywBLxd0= k8s.io/apiextensions-apiserver v0.31.2/go.mod h1:i+Geh+nGCJEGiCGR3MlBDkS7koHIIKWVfWeRFiOsUcM= -k8s.io/apimachinery v0.31.2 h1:i4vUt2hPK56W6mlT7Ry+AO8eEsyxMD1U44NR22CLTYw= -k8s.io/apimachinery v0.31.2/go.mod h1:rsPdaZJfTfLsNJSQzNHQvYoTmxhoOEofxtOsF3rtsMo= -k8s.io/code-generator v0.31.2 h1:xLWxG0HEpMSHfcM//3u3Ro2Hmc6AyyLINQS//Z2GEOI= -k8s.io/code-generator v0.31.2/go.mod h1:eEQHXgBU/m7LDaToDoiz3t97dUUVyOblQdwOr8rivqc= -k8s.io/gengo/v2 v2.0.0-20240228010128-51d4e06bde70 h1:NGrVE502P0s0/1hudf8zjgwki1X/TByhmAoILTarmzo= -k8s.io/gengo/v2 v2.0.0-20240228010128-51d4e06bde70/go.mod h1:VH3AT8AaQOqiGjMF9p0/IM1Dj+82ZwjfxUP1IxaHE+8= +k8s.io/apimachinery v0.32.0 h1:cFSE7N3rmEEtv4ei5X6DaJPHHX0C+upp+v5lVPiEwpg= +k8s.io/apimachinery v0.32.0/go.mod h1:GpHVgxoKlTxClKcteaeuF1Ul/lDVb74KpZcxcmLDElE= +k8s.io/code-generator v0.32.0 h1:s0lNN8VSWny8LBz5t5iy7MCdgwdOhdg7vAGVxvS+VWU= +k8s.io/code-generator v0.32.0/go.mod h1:b7Q7KMZkvsYFy72A79QYjiv4aTz3GvW0f1T3UfhFq4s= +k8s.io/gengo/v2 v2.0.0-20240911193312-2b36238f13e9 h1:si3PfKm8dDYxgfbeA6orqrtLkvvIeH8UqffFJDl0bz4= +k8s.io/gengo/v2 v2.0.0-20240911193312-2b36238f13e9/go.mod h1:EJykeLsmFC60UQbYJezXkEsG2FLrt0GPNkU5iK5GWxU= 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-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= +k8s.io/kube-openapi v0.0.0-20241105132330-32ad38e42d3f h1:GA7//TjRY9yWGy1poLzYYJJ4JRdzg3+O6e8I+e+8T5Y= +k8s.io/kube-openapi v0.0.0-20241105132330-32ad38e42d3f/go.mod h1:R/HEjbvWI0qdfb8viZUeVZm0X6IZnxAydC7YU42CMw4= +k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 h1:M3sRQVHv7vB20Xc2ybTt7ODCeFj6JSWYFzOFnYeS6Ro= +k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= sigs.k8s.io/controller-tools v0.16.5 h1:5k9FNRqziBPwqr17AMEPPV/En39ZBplLAdOwwQHruP4= sigs.k8s.io/controller-tools v0.16.5/go.mod h1:8vztuRVzs8IuuJqKqbXCSlXcw+lkAv/M2sTpg55qjMY= -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/json v0.0.0-20241010143419-9aa6b5e7a4b3 h1:/Rv+M11QRah1itp8VhT6HoVx1Ray9eB4DBr+K+/sCJ8= +sigs.k8s.io/json v0.0.0-20241010143419-9aa6b5e7a4b3/go.mod h1:18nIHnGi6636UCz6m8i4DhaJ65T6EruyzmoQqI2BVDo= sigs.k8s.io/kustomize/api v0.18.0 h1:hTzp67k+3NEVInwz5BHyzc9rGxIauoXferXyjv5lWPo= sigs.k8s.io/kustomize/api v0.18.0/go.mod h1:f8isXnX+8b+SGLHQ6yO4JG1rdkZlvhaCf/uZbLVMb0U= sigs.k8s.io/kustomize/cmd/config v0.15.0 h1:WkdY8V2+8J+W00YbImXa2ke9oegfrHH79e+kywW7EdU= @@ -197,7 +197,7 @@ sigs.k8s.io/kustomize/kustomize/v5 v5.5.0 h1:o1mtt6vpxsxDYaZKrw3BnEtc+pAjLz7Uffn sigs.k8s.io/kustomize/kustomize/v5 v5.5.0/go.mod h1:AeFCmgCrXzmvjWWaeZCyBp6XzG1Y0w1svYus8GhJEOE= sigs.k8s.io/kustomize/kyaml v0.18.1 h1:WvBo56Wzw3fjS+7vBjN6TeivvpbW9GmRaWZ9CIVmt4E= sigs.k8s.io/kustomize/kyaml v0.18.1/go.mod h1:C3L2BFVU1jgcddNBE1TxuVLgS46TjObMwW5FT9FcjYo= -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/structured-merge-diff/v4 v4.4.2 h1:MdmvkGuXi/8io6ixD5wud3vOLwc1rj0aNqRlpuvjmwA= +sigs.k8s.io/structured-merge-diff/v4 v4.4.2/go.mod h1:N8f93tFZh9U6vpxwRArLiikrE5/2tiu1w1AGfACIGE4= sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= From 05c367c519f75bb400740ebef39cb4a65fe1d2a7 Mon Sep 17 00:00:00 2001 From: Tariq Ibrahim Date: Tue, 17 Dec 2024 13:44:30 -0800 Subject: [PATCH 2/3] run go mod tidy Signed-off-by: Tariq Ibrahim --- tools/go.mod | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tools/go.mod b/tools/go.mod index 61fae30df..a4fe1f96d 100644 --- a/tools/go.mod +++ b/tools/go.mod @@ -1,7 +1,8 @@ module github.com/NVIDIA/gpu-operator/tools -go 1.22.7 -toolchain go1.23.2 +go 1.23.0 + +toolchain go1.23.4 require ( k8s.io/code-generator v0.32.0 From bdb7a6e66455e077d93547dbe3c764b73412fd1d Mon Sep 17 00:00:00 2001 From: Tariq Ibrahim Date: Wed, 18 Dec 2024 12:30:46 -0800 Subject: [PATCH 3/3] sync generated clientset code Signed-off-by: Tariq Ibrahim --- api/versioned/clientset.go | 4 +- .../typed/nvidia/v1/clusterpolicy.go | 25 ++-- .../nvidia/v1/fake/fake_clusterpolicy.go | 130 +++-------------- .../nvidia/v1/fake/fake_nvidia_client.go | 2 +- .../typed/nvidia/v1/nvidia_client.go | 10 +- .../v1alpha1/fake/fake_nvidia_client.go | 2 +- .../nvidia/v1alpha1/fake/fake_nvidiadriver.go | 132 +++--------------- .../typed/nvidia/v1alpha1/nvidia_client.go | 10 +- .../typed/nvidia/v1alpha1/nvidiadriver.go | 25 ++-- 9 files changed, 84 insertions(+), 256 deletions(-) diff --git a/api/versioned/clientset.go b/api/versioned/clientset.go index 539960f0f..304e39896 100644 --- a/api/versioned/clientset.go +++ b/api/versioned/clientset.go @@ -19,8 +19,8 @@ package versioned import ( - "fmt" - "net/http" + fmt "fmt" + http "net/http" nvidiav1 "github.com/NVIDIA/gpu-operator/api/versioned/typed/nvidia/v1" nvidiav1alpha1 "github.com/NVIDIA/gpu-operator/api/versioned/typed/nvidia/v1alpha1" diff --git a/api/versioned/typed/nvidia/v1/clusterpolicy.go b/api/versioned/typed/nvidia/v1/clusterpolicy.go index 29d5aa390..b99170526 100644 --- a/api/versioned/typed/nvidia/v1/clusterpolicy.go +++ b/api/versioned/typed/nvidia/v1/clusterpolicy.go @@ -19,9 +19,9 @@ package v1 import ( - "context" + context "context" - v1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1" + nvidiav1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1" scheme "github.com/NVIDIA/gpu-operator/api/versioned/scheme" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" types "k8s.io/apimachinery/pkg/types" @@ -37,33 +37,34 @@ type ClusterPoliciesGetter interface { // ClusterPolicyInterface has methods to work with ClusterPolicy resources. type ClusterPolicyInterface interface { - Create(ctx context.Context, clusterPolicy *v1.ClusterPolicy, opts metav1.CreateOptions) (*v1.ClusterPolicy, error) - Update(ctx context.Context, clusterPolicy *v1.ClusterPolicy, opts metav1.UpdateOptions) (*v1.ClusterPolicy, error) + Create(ctx context.Context, clusterPolicy *nvidiav1.ClusterPolicy, opts metav1.CreateOptions) (*nvidiav1.ClusterPolicy, error) + Update(ctx context.Context, clusterPolicy *nvidiav1.ClusterPolicy, opts metav1.UpdateOptions) (*nvidiav1.ClusterPolicy, error) // Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). - UpdateStatus(ctx context.Context, clusterPolicy *v1.ClusterPolicy, opts metav1.UpdateOptions) (*v1.ClusterPolicy, error) + UpdateStatus(ctx context.Context, clusterPolicy *nvidiav1.ClusterPolicy, opts metav1.UpdateOptions) (*nvidiav1.ClusterPolicy, error) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error - Get(ctx context.Context, name string, opts metav1.GetOptions) (*v1.ClusterPolicy, error) - List(ctx context.Context, opts metav1.ListOptions) (*v1.ClusterPolicyList, error) + Get(ctx context.Context, name string, opts metav1.GetOptions) (*nvidiav1.ClusterPolicy, error) + List(ctx context.Context, opts metav1.ListOptions) (*nvidiav1.ClusterPolicyList, error) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) - Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *v1.ClusterPolicy, err error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *nvidiav1.ClusterPolicy, err error) ClusterPolicyExpansion } // clusterPolicies implements ClusterPolicyInterface type clusterPolicies struct { - *gentype.ClientWithList[*v1.ClusterPolicy, *v1.ClusterPolicyList] + *gentype.ClientWithList[*nvidiav1.ClusterPolicy, *nvidiav1.ClusterPolicyList] } // newClusterPolicies returns a ClusterPolicies func newClusterPolicies(c *NvidiaV1Client) *clusterPolicies { return &clusterPolicies{ - gentype.NewClientWithList[*v1.ClusterPolicy, *v1.ClusterPolicyList]( + gentype.NewClientWithList[*nvidiav1.ClusterPolicy, *nvidiav1.ClusterPolicyList]( "clusterpolicies", c.RESTClient(), scheme.ParameterCodec, "", - func() *v1.ClusterPolicy { return &v1.ClusterPolicy{} }, - func() *v1.ClusterPolicyList { return &v1.ClusterPolicyList{} }), + func() *nvidiav1.ClusterPolicy { return &nvidiav1.ClusterPolicy{} }, + func() *nvidiav1.ClusterPolicyList { return &nvidiav1.ClusterPolicyList{} }, + ), } } diff --git a/api/versioned/typed/nvidia/v1/fake/fake_clusterpolicy.go b/api/versioned/typed/nvidia/v1/fake/fake_clusterpolicy.go index e7bb37f19..b1b5b628e 100644 --- a/api/versioned/typed/nvidia/v1/fake/fake_clusterpolicy.go +++ b/api/versioned/typed/nvidia/v1/fake/fake_clusterpolicy.go @@ -19,120 +19,32 @@ package fake import ( - "context" - v1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1" - metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - labels "k8s.io/apimachinery/pkg/labels" - types "k8s.io/apimachinery/pkg/types" - watch "k8s.io/apimachinery/pkg/watch" - testing "k8s.io/client-go/testing" + nvidiav1 "github.com/NVIDIA/gpu-operator/api/versioned/typed/nvidia/v1" + gentype "k8s.io/client-go/gentype" ) -// FakeClusterPolicies implements ClusterPolicyInterface -type FakeClusterPolicies struct { +// fakeClusterPolicies implements ClusterPolicyInterface +type fakeClusterPolicies struct { + *gentype.FakeClientWithList[*v1.ClusterPolicy, *v1.ClusterPolicyList] Fake *FakeNvidiaV1 } -var clusterpoliciesResource = v1.SchemeGroupVersion.WithResource("clusterpolicies") - -var clusterpoliciesKind = v1.SchemeGroupVersion.WithKind("ClusterPolicy") - -// Get takes name of the clusterPolicy, and returns the corresponding clusterPolicy object, and an error if there is any. -func (c *FakeClusterPolicies) Get(ctx context.Context, name string, options metav1.GetOptions) (result *v1.ClusterPolicy, err error) { - emptyResult := &v1.ClusterPolicy{} - obj, err := c.Fake. - Invokes(testing.NewRootGetActionWithOptions(clusterpoliciesResource, name, options), emptyResult) - if obj == nil { - return emptyResult, err - } - return obj.(*v1.ClusterPolicy), err -} - -// List takes label and field selectors, and returns the list of ClusterPolicies that match those selectors. -func (c *FakeClusterPolicies) List(ctx context.Context, opts metav1.ListOptions) (result *v1.ClusterPolicyList, err error) { - emptyResult := &v1.ClusterPolicyList{} - obj, err := c.Fake. - Invokes(testing.NewRootListActionWithOptions(clusterpoliciesResource, clusterpoliciesKind, opts), emptyResult) - if obj == nil { - return emptyResult, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &v1.ClusterPolicyList{ListMeta: obj.(*v1.ClusterPolicyList).ListMeta} - for _, item := range obj.(*v1.ClusterPolicyList).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 clusterPolicies. -func (c *FakeClusterPolicies) Watch(ctx context.Context, opts metav1.ListOptions) (watch.Interface, error) { - return c.Fake. - InvokesWatch(testing.NewRootWatchActionWithOptions(clusterpoliciesResource, opts)) -} - -// Create takes the representation of a clusterPolicy and creates it. Returns the server's representation of the clusterPolicy, and an error, if there is any. -func (c *FakeClusterPolicies) Create(ctx context.Context, clusterPolicy *v1.ClusterPolicy, opts metav1.CreateOptions) (result *v1.ClusterPolicy, err error) { - emptyResult := &v1.ClusterPolicy{} - obj, err := c.Fake. - Invokes(testing.NewRootCreateActionWithOptions(clusterpoliciesResource, clusterPolicy, opts), emptyResult) - if obj == nil { - return emptyResult, err - } - return obj.(*v1.ClusterPolicy), err -} - -// Update takes the representation of a clusterPolicy and updates it. Returns the server's representation of the clusterPolicy, and an error, if there is any. -func (c *FakeClusterPolicies) Update(ctx context.Context, clusterPolicy *v1.ClusterPolicy, opts metav1.UpdateOptions) (result *v1.ClusterPolicy, err error) { - emptyResult := &v1.ClusterPolicy{} - obj, err := c.Fake. - Invokes(testing.NewRootUpdateActionWithOptions(clusterpoliciesResource, clusterPolicy, opts), emptyResult) - if obj == nil { - return emptyResult, err - } - return obj.(*v1.ClusterPolicy), err -} - -// UpdateStatus was generated because the type contains a Status member. -// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). -func (c *FakeClusterPolicies) UpdateStatus(ctx context.Context, clusterPolicy *v1.ClusterPolicy, opts metav1.UpdateOptions) (result *v1.ClusterPolicy, err error) { - emptyResult := &v1.ClusterPolicy{} - obj, err := c.Fake. - Invokes(testing.NewRootUpdateSubresourceActionWithOptions(clusterpoliciesResource, "status", clusterPolicy, opts), emptyResult) - if obj == nil { - return emptyResult, err - } - return obj.(*v1.ClusterPolicy), err -} - -// Delete takes name of the clusterPolicy and deletes it. Returns an error if one occurs. -func (c *FakeClusterPolicies) Delete(ctx context.Context, name string, opts metav1.DeleteOptions) error { - _, err := c.Fake. - Invokes(testing.NewRootDeleteActionWithOptions(clusterpoliciesResource, name, opts), &v1.ClusterPolicy{}) - return err -} - -// DeleteCollection deletes a collection of objects. -func (c *FakeClusterPolicies) DeleteCollection(ctx context.Context, opts metav1.DeleteOptions, listOpts metav1.ListOptions) error { - action := testing.NewRootDeleteCollectionActionWithOptions(clusterpoliciesResource, opts, listOpts) - - _, err := c.Fake.Invokes(action, &v1.ClusterPolicyList{}) - return err -} - -// Patch applies the patch and returns the patched clusterPolicy. -func (c *FakeClusterPolicies) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts metav1.PatchOptions, subresources ...string) (result *v1.ClusterPolicy, err error) { - emptyResult := &v1.ClusterPolicy{} - obj, err := c.Fake. - Invokes(testing.NewRootPatchSubresourceActionWithOptions(clusterpoliciesResource, name, pt, data, opts, subresources...), emptyResult) - if obj == nil { - return emptyResult, err +func newFakeClusterPolicies(fake *FakeNvidiaV1) nvidiav1.ClusterPolicyInterface { + return &fakeClusterPolicies{ + gentype.NewFakeClientWithList[*v1.ClusterPolicy, *v1.ClusterPolicyList]( + fake.Fake, + "", + v1.SchemeGroupVersion.WithResource("clusterpolicies"), + v1.SchemeGroupVersion.WithKind("ClusterPolicy"), + func() *v1.ClusterPolicy { return &v1.ClusterPolicy{} }, + func() *v1.ClusterPolicyList { return &v1.ClusterPolicyList{} }, + func(dst, src *v1.ClusterPolicyList) { dst.ListMeta = src.ListMeta }, + func(list *v1.ClusterPolicyList) []*v1.ClusterPolicy { return gentype.ToPointerSlice(list.Items) }, + func(list *v1.ClusterPolicyList, items []*v1.ClusterPolicy) { + list.Items = gentype.FromPointerSlice(items) + }, + ), + fake, } - return obj.(*v1.ClusterPolicy), err } diff --git a/api/versioned/typed/nvidia/v1/fake/fake_nvidia_client.go b/api/versioned/typed/nvidia/v1/fake/fake_nvidia_client.go index aca78400a..e3cad223a 100644 --- a/api/versioned/typed/nvidia/v1/fake/fake_nvidia_client.go +++ b/api/versioned/typed/nvidia/v1/fake/fake_nvidia_client.go @@ -29,7 +29,7 @@ type FakeNvidiaV1 struct { } func (c *FakeNvidiaV1) ClusterPolicies() v1.ClusterPolicyInterface { - return &FakeClusterPolicies{c} + return newFakeClusterPolicies(c) } // RESTClient returns a RESTClient that is used to communicate diff --git a/api/versioned/typed/nvidia/v1/nvidia_client.go b/api/versioned/typed/nvidia/v1/nvidia_client.go index 15d235390..20078e71b 100644 --- a/api/versioned/typed/nvidia/v1/nvidia_client.go +++ b/api/versioned/typed/nvidia/v1/nvidia_client.go @@ -19,10 +19,10 @@ package v1 import ( - "net/http" + http "net/http" - v1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1" - "github.com/NVIDIA/gpu-operator/api/versioned/scheme" + nvidiav1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1" + scheme "github.com/NVIDIA/gpu-operator/api/versioned/scheme" rest "k8s.io/client-go/rest" ) @@ -85,10 +85,10 @@ func New(c rest.Interface) *NvidiaV1Client { } func setConfigDefaults(config *rest.Config) error { - gv := v1.SchemeGroupVersion + gv := nvidiav1.SchemeGroupVersion config.GroupVersion = &gv config.APIPath = "/apis" - config.NegotiatedSerializer = scheme.Codecs.WithoutConversion() + config.NegotiatedSerializer = rest.CodecFactoryForGeneratedClient(scheme.Scheme, scheme.Codecs).WithoutConversion() if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() diff --git a/api/versioned/typed/nvidia/v1alpha1/fake/fake_nvidia_client.go b/api/versioned/typed/nvidia/v1alpha1/fake/fake_nvidia_client.go index 05c071875..f91c593a0 100644 --- a/api/versioned/typed/nvidia/v1alpha1/fake/fake_nvidia_client.go +++ b/api/versioned/typed/nvidia/v1alpha1/fake/fake_nvidia_client.go @@ -29,7 +29,7 @@ type FakeNvidiaV1alpha1 struct { } func (c *FakeNvidiaV1alpha1) NVIDIADrivers() v1alpha1.NVIDIADriverInterface { - return &FakeNVIDIADrivers{c} + return newFakeNVIDIADrivers(c) } // RESTClient returns a RESTClient that is used to communicate diff --git a/api/versioned/typed/nvidia/v1alpha1/fake/fake_nvidiadriver.go b/api/versioned/typed/nvidia/v1alpha1/fake/fake_nvidiadriver.go index ef5fd04e6..39be6fa25 100644 --- a/api/versioned/typed/nvidia/v1alpha1/fake/fake_nvidiadriver.go +++ b/api/versioned/typed/nvidia/v1alpha1/fake/fake_nvidiadriver.go @@ -19,120 +19,34 @@ package fake import ( - "context" - v1alpha1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1alpha1" - v1 "k8s.io/apimachinery/pkg/apis/meta/v1" - labels "k8s.io/apimachinery/pkg/labels" - types "k8s.io/apimachinery/pkg/types" - watch "k8s.io/apimachinery/pkg/watch" - testing "k8s.io/client-go/testing" + nvidiav1alpha1 "github.com/NVIDIA/gpu-operator/api/versioned/typed/nvidia/v1alpha1" + gentype "k8s.io/client-go/gentype" ) -// FakeNVIDIADrivers implements NVIDIADriverInterface -type FakeNVIDIADrivers struct { +// fakeNVIDIADrivers implements NVIDIADriverInterface +type fakeNVIDIADrivers struct { + *gentype.FakeClientWithList[*v1alpha1.NVIDIADriver, *v1alpha1.NVIDIADriverList] Fake *FakeNvidiaV1alpha1 } -var nvidiadriversResource = v1alpha1.SchemeGroupVersion.WithResource("nvidiadrivers") - -var nvidiadriversKind = v1alpha1.SchemeGroupVersion.WithKind("NVIDIADriver") - -// Get takes name of the nVIDIADriver, and returns the corresponding nVIDIADriver object, and an error if there is any. -func (c *FakeNVIDIADrivers) Get(ctx context.Context, name string, options v1.GetOptions) (result *v1alpha1.NVIDIADriver, err error) { - emptyResult := &v1alpha1.NVIDIADriver{} - obj, err := c.Fake. - Invokes(testing.NewRootGetActionWithOptions(nvidiadriversResource, name, options), emptyResult) - if obj == nil { - return emptyResult, err - } - return obj.(*v1alpha1.NVIDIADriver), err -} - -// List takes label and field selectors, and returns the list of NVIDIADrivers that match those selectors. -func (c *FakeNVIDIADrivers) List(ctx context.Context, opts v1.ListOptions) (result *v1alpha1.NVIDIADriverList, err error) { - emptyResult := &v1alpha1.NVIDIADriverList{} - obj, err := c.Fake. - Invokes(testing.NewRootListActionWithOptions(nvidiadriversResource, nvidiadriversKind, opts), emptyResult) - if obj == nil { - return emptyResult, err - } - - label, _, _ := testing.ExtractFromListOptions(opts) - if label == nil { - label = labels.Everything() - } - list := &v1alpha1.NVIDIADriverList{ListMeta: obj.(*v1alpha1.NVIDIADriverList).ListMeta} - for _, item := range obj.(*v1alpha1.NVIDIADriverList).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 nVIDIADrivers. -func (c *FakeNVIDIADrivers) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) { - return c.Fake. - InvokesWatch(testing.NewRootWatchActionWithOptions(nvidiadriversResource, opts)) -} - -// Create takes the representation of a nVIDIADriver and creates it. Returns the server's representation of the nVIDIADriver, and an error, if there is any. -func (c *FakeNVIDIADrivers) Create(ctx context.Context, nVIDIADriver *v1alpha1.NVIDIADriver, opts v1.CreateOptions) (result *v1alpha1.NVIDIADriver, err error) { - emptyResult := &v1alpha1.NVIDIADriver{} - obj, err := c.Fake. - Invokes(testing.NewRootCreateActionWithOptions(nvidiadriversResource, nVIDIADriver, opts), emptyResult) - if obj == nil { - return emptyResult, err - } - return obj.(*v1alpha1.NVIDIADriver), err -} - -// Update takes the representation of a nVIDIADriver and updates it. Returns the server's representation of the nVIDIADriver, and an error, if there is any. -func (c *FakeNVIDIADrivers) Update(ctx context.Context, nVIDIADriver *v1alpha1.NVIDIADriver, opts v1.UpdateOptions) (result *v1alpha1.NVIDIADriver, err error) { - emptyResult := &v1alpha1.NVIDIADriver{} - obj, err := c.Fake. - Invokes(testing.NewRootUpdateActionWithOptions(nvidiadriversResource, nVIDIADriver, opts), emptyResult) - if obj == nil { - return emptyResult, err - } - return obj.(*v1alpha1.NVIDIADriver), err -} - -// UpdateStatus was generated because the type contains a Status member. -// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). -func (c *FakeNVIDIADrivers) UpdateStatus(ctx context.Context, nVIDIADriver *v1alpha1.NVIDIADriver, opts v1.UpdateOptions) (result *v1alpha1.NVIDIADriver, err error) { - emptyResult := &v1alpha1.NVIDIADriver{} - obj, err := c.Fake. - Invokes(testing.NewRootUpdateSubresourceActionWithOptions(nvidiadriversResource, "status", nVIDIADriver, opts), emptyResult) - if obj == nil { - return emptyResult, err - } - return obj.(*v1alpha1.NVIDIADriver), err -} - -// Delete takes name of the nVIDIADriver and deletes it. Returns an error if one occurs. -func (c *FakeNVIDIADrivers) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error { - _, err := c.Fake. - Invokes(testing.NewRootDeleteActionWithOptions(nvidiadriversResource, name, opts), &v1alpha1.NVIDIADriver{}) - return err -} - -// DeleteCollection deletes a collection of objects. -func (c *FakeNVIDIADrivers) DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error { - action := testing.NewRootDeleteCollectionActionWithOptions(nvidiadriversResource, opts, listOpts) - - _, err := c.Fake.Invokes(action, &v1alpha1.NVIDIADriverList{}) - return err -} - -// Patch applies the patch and returns the patched nVIDIADriver. -func (c *FakeNVIDIADrivers) Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.NVIDIADriver, err error) { - emptyResult := &v1alpha1.NVIDIADriver{} - obj, err := c.Fake. - Invokes(testing.NewRootPatchSubresourceActionWithOptions(nvidiadriversResource, name, pt, data, opts, subresources...), emptyResult) - if obj == nil { - return emptyResult, err +func newFakeNVIDIADrivers(fake *FakeNvidiaV1alpha1) nvidiav1alpha1.NVIDIADriverInterface { + return &fakeNVIDIADrivers{ + gentype.NewFakeClientWithList[*v1alpha1.NVIDIADriver, *v1alpha1.NVIDIADriverList]( + fake.Fake, + "", + v1alpha1.SchemeGroupVersion.WithResource("nvidiadrivers"), + v1alpha1.SchemeGroupVersion.WithKind("NVIDIADriver"), + func() *v1alpha1.NVIDIADriver { return &v1alpha1.NVIDIADriver{} }, + func() *v1alpha1.NVIDIADriverList { return &v1alpha1.NVIDIADriverList{} }, + func(dst, src *v1alpha1.NVIDIADriverList) { dst.ListMeta = src.ListMeta }, + func(list *v1alpha1.NVIDIADriverList) []*v1alpha1.NVIDIADriver { + return gentype.ToPointerSlice(list.Items) + }, + func(list *v1alpha1.NVIDIADriverList, items []*v1alpha1.NVIDIADriver) { + list.Items = gentype.FromPointerSlice(items) + }, + ), + fake, } - return obj.(*v1alpha1.NVIDIADriver), err } diff --git a/api/versioned/typed/nvidia/v1alpha1/nvidia_client.go b/api/versioned/typed/nvidia/v1alpha1/nvidia_client.go index 1fa172e04..53d81bb46 100644 --- a/api/versioned/typed/nvidia/v1alpha1/nvidia_client.go +++ b/api/versioned/typed/nvidia/v1alpha1/nvidia_client.go @@ -19,10 +19,10 @@ package v1alpha1 import ( - "net/http" + http "net/http" - v1alpha1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1alpha1" - "github.com/NVIDIA/gpu-operator/api/versioned/scheme" + nvidiav1alpha1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1alpha1" + scheme "github.com/NVIDIA/gpu-operator/api/versioned/scheme" rest "k8s.io/client-go/rest" ) @@ -85,10 +85,10 @@ func New(c rest.Interface) *NvidiaV1alpha1Client { } func setConfigDefaults(config *rest.Config) error { - gv := v1alpha1.SchemeGroupVersion + gv := nvidiav1alpha1.SchemeGroupVersion config.GroupVersion = &gv config.APIPath = "/apis" - config.NegotiatedSerializer = scheme.Codecs.WithoutConversion() + config.NegotiatedSerializer = rest.CodecFactoryForGeneratedClient(scheme.Scheme, scheme.Codecs).WithoutConversion() if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() diff --git a/api/versioned/typed/nvidia/v1alpha1/nvidiadriver.go b/api/versioned/typed/nvidia/v1alpha1/nvidiadriver.go index 21ae61bf5..bf73e4f9c 100644 --- a/api/versioned/typed/nvidia/v1alpha1/nvidiadriver.go +++ b/api/versioned/typed/nvidia/v1alpha1/nvidiadriver.go @@ -19,9 +19,9 @@ package v1alpha1 import ( - "context" + context "context" - v1alpha1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1alpha1" + nvidiav1alpha1 "github.com/NVIDIA/gpu-operator/api/nvidia/v1alpha1" scheme "github.com/NVIDIA/gpu-operator/api/versioned/scheme" v1 "k8s.io/apimachinery/pkg/apis/meta/v1" types "k8s.io/apimachinery/pkg/types" @@ -37,33 +37,34 @@ type NVIDIADriversGetter interface { // NVIDIADriverInterface has methods to work with NVIDIADriver resources. type NVIDIADriverInterface interface { - Create(ctx context.Context, nVIDIADriver *v1alpha1.NVIDIADriver, opts v1.CreateOptions) (*v1alpha1.NVIDIADriver, error) - Update(ctx context.Context, nVIDIADriver *v1alpha1.NVIDIADriver, opts v1.UpdateOptions) (*v1alpha1.NVIDIADriver, error) + Create(ctx context.Context, nVIDIADriver *nvidiav1alpha1.NVIDIADriver, opts v1.CreateOptions) (*nvidiav1alpha1.NVIDIADriver, error) + Update(ctx context.Context, nVIDIADriver *nvidiav1alpha1.NVIDIADriver, opts v1.UpdateOptions) (*nvidiav1alpha1.NVIDIADriver, error) // Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus(). - UpdateStatus(ctx context.Context, nVIDIADriver *v1alpha1.NVIDIADriver, opts v1.UpdateOptions) (*v1alpha1.NVIDIADriver, error) + UpdateStatus(ctx context.Context, nVIDIADriver *nvidiav1alpha1.NVIDIADriver, opts v1.UpdateOptions) (*nvidiav1alpha1.NVIDIADriver, error) Delete(ctx context.Context, name string, opts v1.DeleteOptions) error DeleteCollection(ctx context.Context, opts v1.DeleteOptions, listOpts v1.ListOptions) error - Get(ctx context.Context, name string, opts v1.GetOptions) (*v1alpha1.NVIDIADriver, error) - List(ctx context.Context, opts v1.ListOptions) (*v1alpha1.NVIDIADriverList, error) + Get(ctx context.Context, name string, opts v1.GetOptions) (*nvidiav1alpha1.NVIDIADriver, error) + List(ctx context.Context, opts v1.ListOptions) (*nvidiav1alpha1.NVIDIADriverList, error) Watch(ctx context.Context, opts v1.ListOptions) (watch.Interface, error) - Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *v1alpha1.NVIDIADriver, err error) + Patch(ctx context.Context, name string, pt types.PatchType, data []byte, opts v1.PatchOptions, subresources ...string) (result *nvidiav1alpha1.NVIDIADriver, err error) NVIDIADriverExpansion } // nVIDIADrivers implements NVIDIADriverInterface type nVIDIADrivers struct { - *gentype.ClientWithList[*v1alpha1.NVIDIADriver, *v1alpha1.NVIDIADriverList] + *gentype.ClientWithList[*nvidiav1alpha1.NVIDIADriver, *nvidiav1alpha1.NVIDIADriverList] } // newNVIDIADrivers returns a NVIDIADrivers func newNVIDIADrivers(c *NvidiaV1alpha1Client) *nVIDIADrivers { return &nVIDIADrivers{ - gentype.NewClientWithList[*v1alpha1.NVIDIADriver, *v1alpha1.NVIDIADriverList]( + gentype.NewClientWithList[*nvidiav1alpha1.NVIDIADriver, *nvidiav1alpha1.NVIDIADriverList]( "nvidiadrivers", c.RESTClient(), scheme.ParameterCodec, "", - func() *v1alpha1.NVIDIADriver { return &v1alpha1.NVIDIADriver{} }, - func() *v1alpha1.NVIDIADriverList { return &v1alpha1.NVIDIADriverList{} }), + func() *nvidiav1alpha1.NVIDIADriver { return &nvidiav1alpha1.NVIDIADriver{} }, + func() *nvidiav1alpha1.NVIDIADriverList { return &nvidiav1alpha1.NVIDIADriverList{} }, + ), } }