-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(cstorBackup, delete): support for snapshot deletion (#57)
This commit adds support to cleanup backup resources generated by maya-apiserver, to execute backup of CStor volumes. Velero-plugin will execute clean-up operation in following scenarios: - In case of normal backup, Plugin will send delete request to api-server once the backup for the cstor volume completes - In case of scheduled backup, Plugin will send delete request, for second-last completed backup, to api-server. - If backup, normal or scheduled, is failed then plugin will send the delete request to api-server. - In case of scheduled backup, A) If backup is last generated one then Maya-Apiserver will delete the relevant CStorBackup, CStorCompletedBackups and CStor snapshot, so next new backup will be full backup B) If backup is not the last one then maya-apiserver will delete the relevant CStorBackup and CStor snapshot REST API query format: `<APISERVER_ADDR>/latest/backups/<BACKUP_NAME>?volume=<VOL_NAME>&namespace=<PVC_NAMESPACE>&schedule=<SCHEDULE_NAME>` Sample query URL: `http://10.0.0.94:5656/latest/backups/emyqevym-20200401174441?volume=pvc-165d0f86-7441-11ea-9d2c-d89c67d5e4a1&namespace=app&schedule=emyqevym` Covered test cases : 1. Test to verify clean-up of CStorBackup, CStorCompletedBackups and CStor snapshot in case of normal backup 2. Test to verify clean-up of CStorBackup, CStorCompletedBackups and CStor snapshot in case of scheduled backup Signed-off-by: mayank <[email protected]>
- Loading branch information
Showing
9 changed files
with
234 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.