mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-13 10:33:35 +00:00
rebase: update external-snapshotter client to v7
updating external-snapshotter client to use the latest release updates #4435 Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
This commit is contained in:
committed by
mergify[bot]
parent
fbaf9d5485
commit
a45ad5be9f
@ -20,7 +20,7 @@ import (
|
||||
core_v1 "k8s.io/api/core/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
|
||||
snapshotv1 "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumesnapshot/v1"
|
||||
snapshotv1 "github.com/kubernetes-csi/external-snapshotter/client/v7/apis/volumesnapshot/v1"
|
||||
)
|
||||
|
||||
// VolumeGroupSnapshotSpec defines the desired state of a volume group snapshot.
|
||||
@ -52,8 +52,8 @@ type VolumeGroupSnapshotSource struct {
|
||||
// is created, the existing group snapshots won't be modified.
|
||||
// Once a VolumeGroupSnapshotContent is created and the sidecar starts to process
|
||||
// it, the volume list will not change with retries.
|
||||
// Required.
|
||||
Selector metav1.LabelSelector `json:"selector" protobuf:"bytes,1,opt,name=selector"`
|
||||
// +optional
|
||||
Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,1,opt,name=selector"`
|
||||
|
||||
// VolumeGroupSnapshotContentName specifies the name of a pre-existing VolumeGroupSnapshotContent
|
||||
// object representing an existing volume group snapshot.
|
||||
@ -348,16 +348,33 @@ type VolumeGroupSnapshotContentStatus struct {
|
||||
// Exactly one of its members must be set.
|
||||
// Members in VolumeGroupSnapshotContentSource are immutable.
|
||||
type VolumeGroupSnapshotContentSource struct {
|
||||
// PersistentVolumeNames is a list of names of PersistentVolumes to be snapshotted
|
||||
// VolumeHandles is a list of volume handles on the backend to be snapshotted
|
||||
// together. It is specified for dynamic provisioning of the VolumeGroupSnapshot.
|
||||
// This field is immutable.
|
||||
// +optional
|
||||
PersistentVolumeNames []string `json:"persistentVolumeNames,omitempty" protobuf:"bytes,1,opt,name=persistentVolumeNames"`
|
||||
VolumeHandles []string `json:"volumeHandles,omitempty" protobuf:"bytes,1,opt,name=volumeHandles"`
|
||||
|
||||
// GroupSnapshotHandles specifies the CSI "group_snapshot_id" of a pre-existing
|
||||
// group snapshot and a list of CSI "snapshot_id" of pre-existing snapshots
|
||||
// on the underlying storage system for which a Kubernetes object
|
||||
// representation was (or should be) created.
|
||||
// This field is immutable.
|
||||
// +optional
|
||||
GroupSnapshotHandles *GroupSnapshotHandles `json:"groupSnapshotHandles,omitempty" protobuf:"bytes,2,opt,name=groupSnapshotHandles"`
|
||||
}
|
||||
|
||||
type GroupSnapshotHandles struct {
|
||||
// VolumeGroupSnapshotHandle specifies the CSI "group_snapshot_id" of a pre-existing
|
||||
// group snapshot on the underlying storage system for which a Kubernetes object
|
||||
// representation was (or should be) created.
|
||||
// This field is immutable.
|
||||
// +optional
|
||||
VolumeGroupSnapshotHandle *string `json:"volumeGroupSnapshotHandle,omitempty" protobuf:"bytes,2,opt,name=volumeGroupSnapshotHandle"`
|
||||
// Required.
|
||||
VolumeGroupSnapshotHandle string `json:"volumeGroupSnapshotHandle" protobuf:"bytes,1,opt,name=volumeGroupSnapshotHandle"`
|
||||
|
||||
// VolumeSnapshotHandles is a list of CSI "snapshot_id" of pre-existing
|
||||
// snapshots on the underlying storage system for which Kubernetes objects
|
||||
// representation were (or should be) created.
|
||||
// This field is immutable.
|
||||
// Required.
|
||||
VolumeSnapshotHandles []string `json:"volumeSnapshotHandles" protobuf:"bytes,2,opt,name=volumeSnapshotHandles"`
|
||||
}
|
@ -2,7 +2,7 @@
|
||||
// +build !ignore_autogenerated
|
||||
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@ -22,11 +22,33 @@ limitations under the License.
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumesnapshot/v1"
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v7/apis/volumesnapshot/v1"
|
||||
corev1 "k8s.io/api/core/v1"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
)
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *GroupSnapshotHandles) DeepCopyInto(out *GroupSnapshotHandles) {
|
||||
*out = *in
|
||||
if in.VolumeSnapshotHandles != nil {
|
||||
in, out := &in.VolumeSnapshotHandles, &out.VolumeSnapshotHandles
|
||||
*out = make([]string, len(*in))
|
||||
copy(*out, *in)
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GroupSnapshotHandles.
|
||||
func (in *GroupSnapshotHandles) DeepCopy() *GroupSnapshotHandles {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(GroupSnapshotHandles)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *VolumeGroupSnapshot) DeepCopyInto(out *VolumeGroupSnapshot) {
|
||||
*out = *in
|
||||
@ -193,15 +215,15 @@ func (in *VolumeGroupSnapshotContentList) DeepCopyObject() runtime.Object {
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *VolumeGroupSnapshotContentSource) DeepCopyInto(out *VolumeGroupSnapshotContentSource) {
|
||||
*out = *in
|
||||
if in.PersistentVolumeNames != nil {
|
||||
in, out := &in.PersistentVolumeNames, &out.PersistentVolumeNames
|
||||
if in.VolumeHandles != nil {
|
||||
in, out := &in.VolumeHandles, &out.VolumeHandles
|
||||
*out = make([]string, len(*in))
|
||||
copy(*out, *in)
|
||||
}
|
||||
if in.VolumeGroupSnapshotHandle != nil {
|
||||
in, out := &in.VolumeGroupSnapshotHandle, &out.VolumeGroupSnapshotHandle
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
if in.GroupSnapshotHandles != nil {
|
||||
in, out := &in.GroupSnapshotHandles, &out.GroupSnapshotHandles
|
||||
*out = new(GroupSnapshotHandles)
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
return
|
||||
}
|
||||
@ -316,7 +338,11 @@ func (in *VolumeGroupSnapshotList) DeepCopyObject() runtime.Object {
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *VolumeGroupSnapshotSource) DeepCopyInto(out *VolumeGroupSnapshotSource) {
|
||||
*out = *in
|
||||
in.Selector.DeepCopyInto(&out.Selector)
|
||||
if in.Selector != nil {
|
||||
in, out := &in.Selector, &out.Selector
|
||||
*out = new(metav1.LabelSelector)
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
if in.VolumeGroupSnapshotContentName != nil {
|
||||
in, out := &in.VolumeGroupSnapshotContentName, &out.VolumeGroupSnapshotContentName
|
||||
*out = new(string)
|
@ -421,10 +421,10 @@ type VolumeSnapshotContentStatus struct {
|
||||
// +optional
|
||||
Error *VolumeSnapshotError `json:"error,omitempty" protobuf:"bytes,5,opt,name=error,casttype=VolumeSnapshotError"`
|
||||
|
||||
// VolumeGroupSnapshotContentName is the name of the VolumeGroupSnapshotContent of
|
||||
// which this VolumeSnapshotContent is a part of.
|
||||
// VolumeGroupSnapshotHandle is the CSI "group_snapshot_id" of a group snapshot
|
||||
// on the underlying storage system.
|
||||
// +optional
|
||||
VolumeGroupSnapshotContentName *string `json:"volumeGroupSnapshotContentName,omitempty" protobuf:"bytes,6,opt,name=volumeGroupSnapshotContentName"`
|
||||
VolumeGroupSnapshotHandle *string `json:"volumeGroupSnapshotHandle,omitempty" protobuf:"bytes,6,opt,name=volumeGroupSnapshotHandle"`
|
||||
}
|
||||
|
||||
// DeletionPolicy describes a policy for end-of-life maintenance of volume snapshot contents
|
@ -2,7 +2,7 @@
|
||||
// +build !ignore_autogenerated
|
||||
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@ -271,8 +271,8 @@ func (in *VolumeSnapshotContentStatus) DeepCopyInto(out *VolumeSnapshotContentSt
|
||||
*out = new(VolumeSnapshotError)
|
||||
(*in).DeepCopyInto(*out)
|
||||
}
|
||||
if in.VolumeGroupSnapshotContentName != nil {
|
||||
in, out := &in.VolumeGroupSnapshotContentName, &out.VolumeGroupSnapshotContentName
|
||||
if in.VolumeGroupSnapshotHandle != nil {
|
||||
in, out := &in.VolumeGroupSnapshotHandle, &out.VolumeGroupSnapshotHandle
|
||||
*out = new(string)
|
||||
**out = **in
|
||||
}
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@ -19,8 +19,8 @@ limitations under the License.
|
||||
package scheme
|
||||
|
||||
import (
|
||||
groupsnapshotv1alpha1 "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumegroupsnapshot/v1alpha1"
|
||||
snapshotv1 "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumesnapshot/v1"
|
||||
groupsnapshotv1alpha1 "github.com/kubernetes-csi/external-snapshotter/client/v7/apis/volumegroupsnapshot/v1alpha1"
|
||||
snapshotv1 "github.com/kubernetes-csi/external-snapshotter/client/v7/apis/volumesnapshot/v1"
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
schema "k8s.io/apimachinery/pkg/runtime/schema"
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@ -22,8 +22,8 @@ import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumesnapshot/v1"
|
||||
scheme "github.com/kubernetes-csi/external-snapshotter/client/v6/clientset/versioned/scheme"
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v7/apis/volumesnapshot/v1"
|
||||
scheme "github.com/kubernetes-csi/external-snapshotter/client/v7/clientset/versioned/scheme"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@ -21,8 +21,8 @@ package v1
|
||||
import (
|
||||
"net/http"
|
||||
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumesnapshot/v1"
|
||||
"github.com/kubernetes-csi/external-snapshotter/client/v6/clientset/versioned/scheme"
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v7/apis/volumesnapshot/v1"
|
||||
"github.com/kubernetes-csi/external-snapshotter/client/v7/clientset/versioned/scheme"
|
||||
rest "k8s.io/client-go/rest"
|
||||
)
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@ -22,8 +22,8 @@ import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumesnapshot/v1"
|
||||
scheme "github.com/kubernetes-csi/external-snapshotter/client/v6/clientset/versioned/scheme"
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v7/apis/volumesnapshot/v1"
|
||||
scheme "github.com/kubernetes-csi/external-snapshotter/client/v7/clientset/versioned/scheme"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
Copyright 2023 The Kubernetes Authors.
|
||||
Copyright 2024 The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
@ -22,8 +22,8 @@ import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v6/apis/volumesnapshot/v1"
|
||||
scheme "github.com/kubernetes-csi/external-snapshotter/client/v6/clientset/versioned/scheme"
|
||||
v1 "github.com/kubernetes-csi/external-snapshotter/client/v7/apis/volumesnapshot/v1"
|
||||
scheme "github.com/kubernetes-csi/external-snapshotter/client/v7/clientset/versioned/scheme"
|
||||
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
types "k8s.io/apimachinery/pkg/types"
|
||||
watch "k8s.io/apimachinery/pkg/watch"
|
Reference in New Issue
Block a user