Skip to content

Commit 2ec6842

Browse files
committed
Merge branch 'master' into use-central-flags
2 parents d7210ad + f21cb02 commit 2ec6842

File tree

47 files changed

+2315
-1669
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+2315
-1669
lines changed

CHANGELOG/CHANGELOG-8.4.md

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
# Release notes for v8.4.0
2+
3+
[Documentation](https://kubernetes-csi.github.io)
4+
5+
# Changelog since v8.3.0
6+
7+
## Changes by Kind
8+
9+
### API Change
10+
11+
- Introduce the `v1beta2` VolumeGroupSnapshot API as described by [KEP 5013](https://github.com/kubernetes/enhancements/pull/5013) ([#1312](https://github.com/kubernetes-csi/external-snapshotter/pull/1312), [@leonardoce](https://github.com/leonardoce))
12+
13+
### Feature
14+
15+
- The number of worker threads in the snapshot-controller and csi-snapshotter is now configurable via the `worker-threads` flag. ([#282](https://github.com/kubernetes-csi/external-snapshotter/pull/282), [@huffmanca](https://github.com/huffmanca))
16+
17+
### Other (Cleanup or Flake)
18+
19+
- Several VolumeGroupSnapshot, VolumeGroupSnapshotClass and VolumeGroupSnapshotContent fields are now immutable. The `v1beta1` VolumeGroupSnapshot API is now marked as deprecated. ([#1337](https://github.com/kubernetes-csi/external-snapshotter/pull/1337), [@leonardoce](https://github.com/leonardoce))
20+
- Update kubernetes dependencies to v1.34.0 ([#1330](https://github.com/kubernetes-csi/external-snapshotter/pull/1330), [@dobsonj](https://github.com/dobsonj))
21+
22+
### Uncategorized
23+
24+
- Update CSI spec to v1.12. ([#1341](https://github.com/kubernetes-csi/external-snapshotter/pull/1341), [@xing-yang](https://github.com/xing-yang))
25+
26+
## Dependencies
27+
28+
### Added
29+
- github.com/antihax/optional: [v1.0.0](https://github.com/antihax/optional/tree/v1.0.0)
30+
- github.com/envoyproxy/go-control-plane/envoy: [v1.32.4](https://github.com/envoyproxy/go-control-plane/tree/envoy/v1.32.4)
31+
- github.com/envoyproxy/go-control-plane/ratelimit: [v0.1.0](https://github.com/envoyproxy/go-control-plane/tree/ratelimit/v0.1.0)
32+
- github.com/go-jose/go-jose/v4: [v4.0.4](https://github.com/go-jose/go-jose/tree/v4.0.4)
33+
- github.com/godbus/dbus/v5: [v5.0.4](https://github.com/godbus/dbus/tree/v5.0.4)
34+
- github.com/golang-jwt/jwt/v5: [v5.2.2](https://github.com/golang-jwt/jwt/tree/v5.2.2)
35+
- github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus: [v1.0.1](https://github.com/grpc-ecosystem/go-grpc-middleware/tree/providers/prometheus/v1.0.1)
36+
- github.com/grpc-ecosystem/go-grpc-middleware/v2: [v2.3.0](https://github.com/grpc-ecosystem/go-grpc-middleware/tree/v2.3.0)
37+
- github.com/matttproud/golang_protobuf_extensions: [v1.0.1](https://github.com/matttproud/golang_protobuf_extensions/tree/v1.0.1)
38+
- github.com/rogpeppe/fastuuid: [v1.2.0](https://github.com/rogpeppe/fastuuid/tree/v1.2.0)
39+
- github.com/spiffe/go-spiffe/v2: [v2.5.0](https://github.com/spiffe/go-spiffe/tree/v2.5.0)
40+
- github.com/zeebo/errs: [v1.4.0](https://github.com/zeebo/errs/tree/v1.4.0)
41+
- go.etcd.io/raft/v3: v3.6.0
42+
- go.yaml.in/yaml/v2: v2.4.2
43+
- go.yaml.in/yaml/v3: v3.0.4
44+
- k8s.io/apiextensions-apiserver: v0.34.0
45+
- sigs.k8s.io/structured-merge-diff/v6: v6.3.0
46+
47+
### Changed
48+
- cel.dev/expr: v0.19.1 → v0.24.0
49+
- cloud.google.com/go/compute/metadata: v0.5.2 → v0.6.0
50+
- github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp: [v1.24.2 → v1.26.0](https://github.com/GoogleCloudPlatform/opentelemetry-operations-go/compare/detectors/gcp/v1.24.2...detectors/gcp/v1.26.0)
51+
- github.com/cncf/xds/go: [b4127c9 → 2f00578](https://github.com/cncf/xds/compare/b4127c9...2f00578)
52+
- github.com/container-storage-interface/spec: [v1.11.0 → v1.12.0](https://github.com/container-storage-interface/spec/compare/v1.11.0...v1.12.0)
53+
- github.com/cpuguy83/go-md2man/v2: [v2.0.4 → v2.0.6](https://github.com/cpuguy83/go-md2man/compare/v2.0.4...v2.0.6)
54+
- github.com/emicklei/go-restful/v3: [v3.12.1 → v3.12.2](https://github.com/emicklei/go-restful/compare/v3.12.1...v3.12.2)
55+
- github.com/envoyproxy/go-control-plane: [v0.13.1 → v0.13.4](https://github.com/envoyproxy/go-control-plane/compare/v0.13.1...v0.13.4)
56+
- github.com/envoyproxy/protoc-gen-validate: [v1.1.0 → v1.2.1](https://github.com/envoyproxy/protoc-gen-validate/compare/v1.1.0...v1.2.1)
57+
- github.com/fsnotify/fsnotify: [v1.7.0 → v1.9.0](https://github.com/fsnotify/fsnotify/compare/v1.7.0...v1.9.0)
58+
- github.com/fxamacker/cbor/v2: [v2.7.0 → v2.9.0](https://github.com/fxamacker/cbor/compare/v2.7.0...v2.9.0)
59+
- github.com/golang/glog: [v1.2.2 → v1.2.4](https://github.com/golang/glog/compare/v1.2.2...v1.2.4)
60+
- github.com/google/cel-go: [v0.23.2 → v0.26.0](https://github.com/google/cel-go/compare/v0.23.2...v0.26.0)
61+
- github.com/google/gnostic-models: [v0.6.9 → v0.7.0](https://github.com/google/gnostic-models/compare/v0.6.9...v0.7.0)
62+
- github.com/google/pprof: [d1b30fe → 40e02aa](https://github.com/google/pprof/compare/d1b30fe...40e02aa)
63+
- github.com/grpc-ecosystem/grpc-gateway/v2: [v2.24.0 → v2.26.3](https://github.com/grpc-ecosystem/grpc-gateway/compare/v2.24.0...v2.26.3)
64+
- github.com/jonboulle/clockwork: [v0.4.0 → v0.5.0](https://github.com/jonboulle/clockwork/compare/v0.4.0...v0.5.0)
65+
- github.com/kubernetes-csi/csi-test/v5: [v5.3.1 → v5.4.0](https://github.com/kubernetes-csi/csi-test/compare/v5.3.1...v5.4.0)
66+
- github.com/modern-go/reflect2: [v1.0.2 → 35a7c28](https://github.com/modern-go/reflect2/compare/v1.0.2...35a7c28)
67+
- github.com/onsi/ginkgo/v2: [v2.21.0 → v2.22.0](https://github.com/onsi/ginkgo/compare/v2.21.0...v2.22.0)
68+
- github.com/onsi/gomega: [v1.35.1 → v1.36.1](https://github.com/onsi/gomega/compare/v1.35.1...v1.36.1)
69+
- github.com/spf13/cobra: [v1.8.1 → v1.9.1](https://github.com/spf13/cobra/compare/v1.8.1...v1.9.1)
70+
- github.com/spf13/pflag: [v1.0.5 → v1.0.6](https://github.com/spf13/pflag/compare/v1.0.5...v1.0.6)
71+
- go.etcd.io/bbolt: v1.3.11 → v1.4.2
72+
- go.etcd.io/etcd/api/v3: v3.5.21 → v3.6.4
73+
- go.etcd.io/etcd/client/pkg/v3: v3.5.21 → v3.6.4
74+
- go.etcd.io/etcd/client/v3: v3.5.21 → v3.6.4
75+
- go.etcd.io/etcd/pkg/v3: v3.5.21 → v3.6.4
76+
- go.etcd.io/etcd/server/v3: v3.5.21 → v3.6.4
77+
- go.opentelemetry.io/contrib/detectors/gcp: v1.31.0 → v1.34.0
78+
- go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc: v0.58.0 → v0.60.0
79+
- go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc: v1.33.0 → v1.34.0
80+
- go.opentelemetry.io/otel/exporters/otlp/otlptrace: v1.33.0 → v1.34.0
81+
- go.opentelemetry.io/otel/metric: v1.33.0 → v1.35.0
82+
- go.opentelemetry.io/otel/sdk/metric: v1.31.0 → v1.34.0
83+
- go.opentelemetry.io/otel/sdk: v1.33.0 → v1.34.0
84+
- go.opentelemetry.io/otel/trace: v1.33.0 → v1.35.0
85+
- go.opentelemetry.io/otel: v1.33.0 → v1.35.0
86+
- go.opentelemetry.io/proto/otlp: v1.4.0 → v1.5.0
87+
- golang.org/x/mod: v0.20.0 → v0.21.0
88+
- golang.org/x/tools: v0.26.0 → v0.28.0
89+
- google.golang.org/genproto/googleapis/api: e6fa225 → a0af3ef
90+
- google.golang.org/genproto/googleapis/rpc: 9240e9c → a0af3ef
91+
- google.golang.org/grpc: v1.69.0 → v1.72.1
92+
- k8s.io/api: v0.33.0 → v0.34.0
93+
- k8s.io/apimachinery: v0.33.0 → v0.34.0
94+
- k8s.io/apiserver: v0.33.0 → v0.34.0
95+
- k8s.io/client-go: v0.33.0 → v0.34.0
96+
- k8s.io/code-generator: v0.33.0 → v0.34.0
97+
- k8s.io/component-base: v0.33.0 → v0.34.0
98+
- k8s.io/component-helpers: v0.33.0 → v0.34.0
99+
- k8s.io/gengo/v2: a7b603a → 85fd79d
100+
- k8s.io/kms: v0.33.0 → v0.34.0
101+
- k8s.io/kube-openapi: c8a335a → f3f2b99
102+
- k8s.io/utils: 24370be → 4c0f3b2
103+
- sigs.k8s.io/yaml: v1.4.0 → v1.6.0
104+
105+
### Removed
106+
- github.com/census-instrumentation/opencensus-proto: [v0.4.1](https://github.com/census-instrumentation/opencensus-proto/tree/v0.4.1)
107+
- github.com/go-task/slim-sprig: [52ccab3](https://github.com/go-task/slim-sprig/tree/52ccab3)
108+
- github.com/golang-jwt/jwt/v4: [v4.5.2](https://github.com/golang-jwt/jwt/tree/v4.5.2)
109+
- github.com/grpc-ecosystem/go-grpc-middleware: [v1.3.0](https://github.com/grpc-ecosystem/go-grpc-middleware/tree/v1.3.0)
110+
- github.com/grpc-ecosystem/grpc-gateway: [v1.16.0](https://github.com/grpc-ecosystem/grpc-gateway/tree/v1.16.0)
111+
- go.etcd.io/etcd/client/v2: v2.305.21
112+
- go.etcd.io/etcd/raft/v3: v3.5.21
113+
- google.golang.org/genproto: ef43131

client/apis/volumegroupsnapshot/v1beta1/types.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,7 @@ type VolumeGroupSnapshotStatus struct {
119119
// +kubebuilder:object:root=true
120120
// +kubebuilder:resource:scope=Namespaced,shortName=vgs
121121
// +kubebuilder:subresource:status
122+
// +kubebuilder:deprecatedversion
122123
// +kubebuilder:printcolumn:name="ReadyToUse",type=boolean,JSONPath=`.status.readyToUse`,description="Indicates if all the individual snapshots in the group are ready to be used to restore a group of volumes."
123124
// +kubebuilder:printcolumn:name="VolumeGroupSnapshotClass",type=string,JSONPath=`.spec.volumeGroupSnapshotClassName`,description="The name of the VolumeGroupSnapshotClass requested by the VolumeGroupSnapshot."
124125
// +kubebuilder:printcolumn:name="VolumeGroupSnapshotContent",type=string,JSONPath=`.status.boundVolumeGroupSnapshotContentName`,description="Name of the VolumeGroupSnapshotContent object to which the VolumeGroupSnapshot object intends to bind to. Please note that verification of binding actually requires checking both VolumeGroupSnapshot and VolumeGroupSnapshotContent to ensure both are pointing at each other. Binding MUST be verified prior to usage of this object."
@@ -162,6 +163,7 @@ type VolumeGroupSnapshotList struct {
162163
// is used by specifying its name in a VolumeGroupSnapshot object.
163164
// VolumeGroupSnapshotClasses are non-namespaced.
164165
// +kubebuilder:object:root=true
166+
// +kubebuilder:deprecatedversion
165167
// +kubebuilder:resource:scope=Cluster,shortName=vgsclass;vgsclasses
166168
// +kubebuilder:printcolumn:name="Driver",type=string,JSONPath=`.driver`
167169
// +kubebuilder:printcolumn:name="DeletionPolicy",type=string,JSONPath=`.deletionPolicy`,description="Determines whether a VolumeGroupSnapshotContent created through the VolumeGroupSnapshotClass should be deleted when its bound VolumeGroupSnapshot is deleted."
@@ -218,6 +220,7 @@ type VolumeGroupSnapshotClassList struct {
218220
// in the underlying storage system
219221
// +kubebuilder:object:root=true
220222
// +kubebuilder:resource:scope=Cluster,shortName=vgsc;vgscs
223+
// +kubebuilder:deprecatedversion
221224
// +kubebuilder:subresource:status
222225
// +kubebuilder:printcolumn:name="ReadyToUse",type=boolean,JSONPath=`.status.readyToUse`,description="Indicates if all the individual snapshots in the group are ready to be used to restore a group of volumes."
223226
// +kubebuilder:printcolumn:name="DeletionPolicy",type=string,JSONPath=`.spec.deletionPolicy`,description="Determines whether this VolumeGroupSnapshotContent and its physical group snapshot on the underlying storage system should be deleted when its bound VolumeGroupSnapshot is deleted."

client/apis/volumegroupsnapshot/v1beta2/types.go

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -80,16 +80,14 @@ type VolumeGroupSnapshotStatus struct {
8080
// VolumeGroupSnapshot and VolumeGroupSnapshotContent objects is successful
8181
// (by validating that both VolumeGroupSnapshot and VolumeGroupSnapshotContent
8282
// point at each other) before using this object.
83+
// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="boundVolumeGroupSnapshotContentName is immutable once set"
8384
// +optional
8485
BoundVolumeGroupSnapshotContentName *string `json:"boundVolumeGroupSnapshotContentName,omitempty" protobuf:"bytes,1,opt,name=boundVolumeGroupSnapshotContentName"`
8586

8687
// CreationTime is the timestamp when the point-in-time group snapshot is taken
8788
// by the underlying storage system.
8889
// If not specified, it may indicate that the creation time of the group snapshot
8990
// is unknown.
90-
// The format of this field is a Unix nanoseconds time encoded as an int64.
91-
// On Unix, the command date +%s%N returns the current time in nanoseconds
92-
// since 1970-01-01 00:00:00 UTC.
9391
// This field is updated based on the CreationTime field in VolumeGroupSnapshotContentStatus
9492
// +optional
9593
CreationTime *metav1.Time `json:"creationTime,omitempty" protobuf:"bytes,2,opt,name=creationTime"`
@@ -177,11 +175,13 @@ type VolumeGroupSnapshotClass struct {
177175

178176
// Driver is the name of the storage driver expected to handle this VolumeGroupSnapshotClass.
179177
// Required.
178+
// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="driver is immutable once set"
180179
Driver string `json:"driver" protobuf:"bytes,2,opt,name=driver"`
181180

182181
// Parameters is a key-value map with storage driver specific parameters for
183182
// creating group snapshots.
184183
// These values are opaque to Kubernetes and are passed directly to the driver.
184+
// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="parameters are immutable once set"
185185
// +optional
186186
Parameters map[string]string `json:"parameters,omitempty" protobuf:"bytes,3,rep,name=parameters"`
187187

@@ -194,6 +194,7 @@ type VolumeGroupSnapshotClass struct {
194194
// "Delete" means that the VolumeGroupSnapshotContent and its physical group
195195
// snapshot on underlying storage system are deleted.
196196
// Required.
197+
// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="deletionPolicy is immutable once set"
197198
DeletionPolicy snapshotv1.DeletionPolicy `json:"deletionPolicy" protobuf:"bytes,4,opt,name=deletionPolicy"`
198199
}
199200

@@ -270,6 +271,8 @@ type VolumeGroupSnapshotContentSpec struct {
270271
// This field is immutable after creation.
271272
// Required.
272273
// +kubebuilder:validation:XValidation:rule="has(self.name) && has(self.__namespace__)",message="both volumeGroupSnapshotRef.name and volumeGroupSnapshotRef.namespace must be set"
274+
// +kubebuilder:validation:XValidation:rule="self.name == oldSelf.name && self.__namespace__ == oldSelf.__namespace__",message="volumeGroupSnapshotRef.name and volumeGroupSnapshotRef.namespace are immutable"
275+
// +kubebuilder:validation:XValidation:rule="!has(oldSelf.uid) || (has(self.uid) && self.uid == oldSelf.uid)",message="volumeGroupSnapshotRef.uid is immutable once set"
273276
VolumeGroupSnapshotRef core_v1.ObjectReference `json:"volumeGroupSnapshotRef" protobuf:"bytes,1,opt,name=volumeGroupSnapshotRef"`
274277

275278
// DeletionPolicy determines whether this VolumeGroupSnapshotContent and the
@@ -293,6 +296,7 @@ type VolumeGroupSnapshotContentSpec struct {
293296
// This MUST be the same as the name returned by the CSI GetPluginName() call for
294297
// that driver.
295298
// Required.
299+
// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="driver is immutable once set"
296300
Driver string `json:"driver" protobuf:"bytes,3,opt,name=driver"`
297301

298302
// VolumeGroupSnapshotClassName is the name of the VolumeGroupSnapshotClass from
@@ -303,6 +307,7 @@ type VolumeGroupSnapshotContentSpec struct {
303307
// For dynamic provisioning, this field must be set.
304308
// This field may be unset for pre-provisioned snapshots.
305309
// +optional
310+
// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="volumeGroupSnapshotClassName is immutable once set"
306311
VolumeGroupSnapshotClassName *string `json:"volumeGroupSnapshotClassName,omitempty" protobuf:"bytes,4,opt,name=volumeGroupSnapshotClassName"`
307312

308313
// Source specifies whether the snapshot is (or should be) dynamically provisioned
@@ -344,15 +349,13 @@ type VolumeGroupSnapshotContentStatus struct {
344349
// If a storage system does not provide such an id, the
345350
// CSI driver can choose to return the VolumeGroupSnapshot name.
346351
// +optional
352+
// +kubebuilder:validation:XValidation:rule="self == oldSelf",message="volumeGroupSnapshotHandle is immutable once set"
347353
VolumeGroupSnapshotHandle *string `json:"volumeGroupSnapshotHandle,omitempty" protobuf:"bytes,1,opt,name=volumeGroupSnapshotHandle"`
348354

349355
// CreationTime is the timestamp when the point-in-time group snapshot is taken
350356
// by the underlying storage system.
351357
// If not specified, it indicates the creation time is unknown.
352358
// If not specified, it means the readiness of a group snapshot is unknown.
353-
// The format of this field is a Unix nanoseconds time encoded as an int64.
354-
// On Unix, the command date +%s%N returns the current time in nanoseconds
355-
// since 1970-01-01 00:00:00 UTC.
356359
// This field is the source for the CreationTime field in VolumeGroupSnapshotStatus
357360
// +optional
358361
CreationTime *metav1.Time `json:"creationTime,omitempty" protobuf:"bytes,2,opt,name=creationTime"`

client/config/crd/groupsnapshot.storage.k8s.io_volumegroupsnapshotclasses.yaml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
33
kind: CustomResourceDefinition
44
metadata:
55
annotations:
6-
api-approved.kubernetes.io: "https://github.com/kubernetes-csi/external-snapshotter/pull/1150"
6+
api-approved.kubernetes.io: "https://github.com/kubernetes-csi/external-snapshotter/pull/1337"
77
controller-gen.kubebuilder.io/version: v0.15.0
88
name: volumegroupsnapshotclasses.groupsnapshot.storage.k8s.io
99
spec:
@@ -31,6 +31,7 @@ spec:
3131
- jsonPath: .metadata.creationTimestamp
3232
name: Age
3333
type: date
34+
deprecated: true
3435
name: v1beta1
3536
schema:
3637
openAPIV3Schema:
@@ -136,11 +137,17 @@ spec:
136137
- Delete
137138
- Retain
138139
type: string
140+
x-kubernetes-validations:
141+
- message: deletionPolicy is immutable once set
142+
rule: self == oldSelf
139143
driver:
140144
description: |-
141145
Driver is the name of the storage driver expected to handle this VolumeGroupSnapshotClass.
142146
Required.
143147
type: string
148+
x-kubernetes-validations:
149+
- message: driver is immutable once set
150+
rule: self == oldSelf
144151
kind:
145152
description: |-
146153
Kind is a string value representing the REST resource this object represents.
@@ -159,6 +166,9 @@ spec:
159166
creating group snapshots.
160167
These values are opaque to Kubernetes and are passed directly to the driver.
161168
type: object
169+
x-kubernetes-validations:
170+
- message: parameters are immutable once set
171+
rule: self == oldSelf
162172
required:
163173
- deletionPolicy
164174
- driver

0 commit comments

Comments
 (0)