294 Commits

Author SHA1 Message Date
Connor Catlett
35579f2803 Discard unnecessary VolumeSnapshotContent updates to prevent rapid RPC calls
Signed-off-by: Connor Catlett <conncatl@amazon.com>
2024-02-29 18:42:37 +00:00
Niels de Vos
aa837d1ddf Fix detecting default annotation on VolumeGroupSnapshotClass
The `IsDefaultAnnotation()` function has been extended to check for the
correct default annotation, taking the Kind of the object into
consideration.
2024-02-22 12:23:17 +01:00
Madhu Rajanna
5706ab6ac8 use GroupSnapshotDeleteError type for event
use GroupSnapshotDeleteError as event type for
event incase if there is any failure in delete
operation.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2024-02-20 08:43:14 +01:00
Madhu Rajanna
0fe3abb9f1 fix method name in logging
updating code to use correct method
names for logging.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2024-02-20 08:41:14 +01:00
Madhu Rajanna
5a7115d61d Add snapshot size to VSC created for VGS
Currently the RestoreSize is missing when
the corresponding VSC are created for the
the volumesnapshotgroup, This PR adds the missing
RestoreSize for VSC.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2024-02-14 15:39:17 +01:00
xing-yang
36738cd8bc Add nil check for SourceVolumeMode in the ValidationWebHook 2024-02-09 12:53:14 -05:00
xing-yang
3ed4ebd3d8 Use client v7 2024-01-30 17:40:58 -05:00
Niels de Vos
d0f443f564 implement GroupSnapshotter.GetGroupSnapshotStatus() 2024-01-30 09:22:07 +01:00
Niels de Vos
9e58d4cc61 Selector in VolumeGroupSnapshotSource API should be optional 2024-01-26 17:27:25 +01:00
Raunak Pradip Shah
e6dc65fefe Fix unit test and remove comments 2024-01-08 10:12:47 -08:00
Raunak Pradip Shah
0bd355cf29 update API names in group snapshot content to be consistent with volume snapshots 2024-01-05 11:29:51 -08:00
Raunak Pradip Shah
bffa5ae25f Update to API for static group volume snapshots 2024-01-05 11:29:42 -08:00
Alex Kalenyuk
895dc73977 Enable prevent-volume-mode-conversion by default following k8s 1.28 release
This is beta since 1.27 so we can safely default to true, to get this new validation logic.
https://github.com/kubernetes/enhancements/blob/master/keps/sig-storage/3141-prevent-volume-mode-conversion/kep.yaml#L30

Signed-off-by: Alex Kalenyuk <akalenyu@redhat.com>
2023-12-10 14:23:29 +02:00
Raunak Pradip Shah
47e71db17f add comments and fix unit test 2023-12-07 09:20:11 -08:00
Raunak Pradip Shah
875662b365 Add finalizer to indicate volume snapshot is part of a group 2023-12-06 16:16:30 -08:00
Sunny Song
7603bf1c4e Update dependency go modules for k8s v1.29.0-rc.1 2023-11-29 22:24:11 +00:00
Raunak Pradip Shah
060ee23d6d Delete individual volume snapshots as part of the group snapshot delete API and prevent users from deleting individual volume snapshots if it is part of an existing group snapshot
Also revert commit bb29899ca3.
2023-11-17 14:24:55 +05:30
Jan Safranek
8a29bf5b21 Re-queue SnapshotContents that are readyToUse: false
SnapshotContents with readyToUse: false should be periodically requeued
with exp. backoff until the CSI driver confirms the snapshot is ready.
2023-11-16 15:37:48 +01:00
Jan Safranek
f9e125b994 Check sync error in unit test properly
Tests must fail when syncContent() returns success and error was expected.
2023-11-16 15:37:48 +01:00
Raunak Pradip Shah
42151b59aa change VolumeGroupSnapshotContentName to VolumeGroupSnapshotHandle in snapshot content status 2023-11-08 12:06:06 +05:30
Raunak Pradip Shah
facefbad6e add DeleteVolumeGroupSnapshot API to delete group snapshot 2023-11-03 13:14:00 +05:30
Rakshith R
aafc456527 add cmdline args to enable group snapshot webhooks
VolumeGroupSnapshots are still in alpha.
This commit adds cmdline args to enable group snapshot
webhooks while keeping it disbaled by default.

Signed-off-by: Rakshith R <rakshith.r.0001@gmail.com>
2023-10-17 15:51:12 +05:30
Kubernetes Prow Robot
215f12f66e Merge pull request #876 from shubham-pampattiwar/fix-issue-748
Update VolumeSnapshot and VolumeSnapshotContent using JSON patch
2023-09-18 17:18:06 -07:00
Shubham Pampattiwar
ff71329d8c Update VolumeSnapshot and VolumeSnapshotContent using JSON patch
fix unit tests

operate on cloned copy

revert to update call for removeSnapshotFinalizer

fix content delete finalizer
2023-09-15 12:17:38 -07:00
Jan Safranek
28b91e65e9 Update to csi-lib-utils@v0.15.0
Manually update to csi-lib-utils@v0.15.0

It was necessary to update to kubernetes-csi/csi-test@v5.1.0 to remove dependency on cloud.google.com/go@v0.34
2023-09-15 17:10:56 +02:00
xing-yang
fd03420fd8 Remove direct dep on kubernetes 2023-09-13 16:24:33 +00:00
Kubernetes Prow Robot
02d7070af8 Merge pull request #869 from testwill/ioutil
chore: remove refs to deprecated io/ioutil
2023-07-20 21:48:06 -07:00
Sameer Shaikh
7fac9cdaf8 external-snapshotter constantly retrying CreateSnapshot calls on error w/o backoff 2023-06-29 21:17:27 +05:30
Sameer Shaikh
d8e698f609 external-snapshotter constantly retrying CreateSnapshot calls on error w/o backoff 2023-06-29 08:03:57 +05:30
Sameer Shaikh
ffaba0f81d external-snapshotter constantly retrying CreateSnapshot calls on error w/o backoff 2023-06-28 18:32:07 +05:30
Sameer Shaikh
a8c9b7b644 external-snapshotter constantly retrying CreateSnapshot calls on error w/o backoff 2023-06-28 15:59:21 +05:30
Sameer Shaikh
98939c02c5 external-snapshotter constantly retrying CreateSnapshot calls on error w/o backoff
Signed-off-by: Sameer Shaikh <sameer.shaikh@ibm.com>
2023-06-28 13:17:42 +05:30
guoguangwu
62c611a51a chore: remove refs to deprecated io/ioutil 2023-06-25 11:09:17 +08:00
Rakshith R
a3cb5a927f add groupsnapshot related webhooks 2023-05-08 18:25:23 +05:30
Raunak Pradip Shah
dbfa2c75fc remove ptypes 2023-05-03 22:34:39 +05:30
Raunak Pradip Shah
21acc924d7 Fix typos 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
1a93d9f551 Add volume snapshot ref details to group snapshot 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
65fbb48cd7 Change timestamp format in volumesnapshot and content names 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
80893cb871 Add hash of PVC UUID to group snapshot names 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
e26501e510 Add reference details to volume group snapshot content status 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
9e2d4f6264 Add groupSnapshotNamePrefix and groupSnapshotNameUUIDLength CLI options 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
d8d01a38e4 Change all occurences of content to group snapshot content 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
871312988b Added create group volume snapshot functionality 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
299862c783 Add csi snapshotter functionality for volume group snapshots 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
09b36e73ae Add syncGroupSnapshotContent and related functions 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
3c32e81fe0 SyncUnreadyGroupSnapshot and related functions 2023-05-03 21:21:32 +05:30
Raunak Pradip Shah
a574b8780c -Introduce volume group snapshot functionality include initializing queues and caches in snapshotter
- Introduce new flag for volume group snapshots and run worker if flag is enabled
- Introduce the main controller for group snapshots in snapshot-controller
2023-05-03 21:21:32 +05:30
Matthew Brooks
8a11d50738 Switch to using google.golang.org/protobuf rather than github.com/golang/protobuf 2023-04-16 14:55:02 -06:00
Humble Chirammal
461143ec25 update client package with go 1.19 formatting changes
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
2022-09-14 08:26:30 +05:30
Humble Chirammal
d34102faae make the formatting errors based on go 1.19
Reference#
https://github.com/kubernetes-csi/csi-release-tools/pull/203

Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
2022-09-13 19:37:34 +05:30