Skip to content
This repository was archived by the owner on Dec 6, 2024. It is now read-only.

Commit 4bde850

Browse files
committed
fix(deletionPolicy): wrong case
1 parent 76de08e commit 4bde850

File tree

3 files changed

+12
-13
lines changed

3 files changed

+12
-13
lines changed

Diff for: apis/objectstorage/v1alpha1/types.go

+10-11
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ func init() {
3333
type DeletionPolicy string
3434

3535
const (
36-
DeletionPolicyRetain DeletionPolicy = "Retain"
37-
DeletionPolicyDelete DeletionPolicy = "Delete"
36+
DeletionPolicyRetain DeletionPolicy = "Retain"
37+
DeletionPolicyDelete DeletionPolicy = "Delete"
3838
)
3939

4040
type Protocol string
@@ -60,8 +60,8 @@ const (
6060
// +kubebuilder:subresource:status
6161
type Bucket struct {
6262
metav1.TypeMeta `json:",inline"`
63-
// +optional
6463

64+
// +optional
6565
metav1.ObjectMeta `json:"metadata,omitempty"`
6666

6767
Spec BucketSpec `json:"spec,omitempty"`
@@ -77,7 +77,7 @@ type BucketSpec struct {
7777
// Name of the BucketClass specified in the BucketRequest
7878
BucketClassName string `json:"bucketClassName"`
7979

80-
// Name of the BucketClaim that resulted in the creation of this Bucket
80+
// Name of the BucketClaim that resulted in the creation of this Bucket
8181
// In case the Bucket object was created manually, then this should refer
8282
// to the BucketClaim with which this Bucket should be bound
8383
BucketClaim *corev1.ObjectReference `json:"bucketClaim"`
@@ -98,7 +98,7 @@ type BucketSpec struct {
9898
// - Delete: Indicates that the bucket should be deleted from the OSP
9999
// once all the workloads accessing this bucket are done
100100
// +optional
101-
// +kubebuilder:default:=retain
101+
// +kubebuilder:default:=Retain
102102
DeletionPolicy DeletionPolicy `json:"deletionPolicy"`
103103

104104
// ExistingBucketID is the unique id of the bucket in the OSP. This field should be
@@ -134,8 +134,8 @@ type BucketList struct {
134134
// +kubebuilder:storageversion
135135
type BucketClaim struct {
136136
metav1.TypeMeta `json:",inline"`
137-
// +optional
138137

138+
// +optional
139139
metav1.ObjectMeta `json:"metadata,omitempty"`
140140

141141
Spec BucketClaimSpec `json:"spec,omitempty"`
@@ -168,7 +168,7 @@ type BucketClaimStatus struct {
168168
BucketReady bool `json:"bucketReady"`
169169

170170
// BucketName is the name of the provisioned Bucket in response
171-
// to this BucketClaim. It is generated and set by the COSI controller
171+
// to this BucketClaim. It is generated and set by the COSI controller
172172
// before making the creation request to the OSP backend.
173173
// +optional
174174
BucketName string `json:"bucketName,omitempty"`
@@ -202,7 +202,7 @@ type BucketClass struct {
202202
// - Retain: Indicates that the bucket should not be deleted from the OSP
203203
// - Delete: Indicates that the bucket should be deleted from the OSP
204204
// once all the workloads accessing this bucket are done
205-
// +kubebuilder:default:=retain
205+
// +kubebuilder:default:=Retain
206206
DeletionPolicy DeletionPolicy `json:"deletionPolicy"`
207207

208208
// Parameters is an opaque map for passing in configuration to a driver
@@ -276,11 +276,11 @@ type BucketAccessSpec struct {
276276
// BucketClaimName is the name of the BucketClaim.
277277
BucketClaimName string `json:"bucketClaimName"`
278278

279-
// Protocol is the name of the Protocol
279+
// Protocol is the name of the Protocol
280280
// that this access credential is supposed to support
281281
// If left empty, it will choose the protocol supported
282282
// by the bucket. If the bucket supports multiple protocols,
283-
// the end protocol is determined by the driver.
283+
// the end protocol is determined by the driver.
284284
// +optional
285285
Protocol Protocol `json:"protocol,omitempty"`
286286

@@ -317,4 +317,3 @@ type BucketAccessList struct {
317317
metav1.ListMeta `json:"metadata,omitempty"`
318318
Items []BucketAccess `json:"items"`
319319
}
320-

Diff for: crds/objectstorage.k8s.io_bucketclasses.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ spec:
2525
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
2626
type: string
2727
deletionPolicy:
28-
default: retain
28+
default: Retain
2929
description: 'DeletionPolicy is used to specify how COSI should handle
3030
deletion of this bucket. There are 2 possible values: - Retain: Indicates
3131
that the bucket should not be deleted from the OSP - Delete: Indicates

Diff for: crds/objectstorage.k8s.io_buckets.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ spec:
7777
description: Name of the BucketClass specified in the BucketRequest
7878
type: string
7979
deletionPolicy:
80-
default: retain
80+
default: Retain
8181
description: 'DeletionPolicy is used to specify how COSI should handle
8282
deletion of this bucket. There are 2 possible values: - Retain:
8383
Indicates that the bucket should not be deleted from the OSP (default)

0 commit comments

Comments
 (0)