cephfs: add set/Get/List/Remove metadata utility functions

Add utility functions to set/Get/List/Remove PV/PVC/PVCNamespace metadata
on subvolume.

Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
This commit is contained in:
Prasanna Kumar Kalever
2022-05-24 19:31:35 +05:30
committed by mergify[bot]
parent 8c5563a9bc
commit ecf03eb6ae
2 changed files with 74 additions and 0 deletions

View File

@ -72,6 +72,11 @@ type SubVolumeClient interface {
CreateCloneFromSnapshot(ctx context.Context, snap Snapshot) error
// CleanupSnapshotFromSubvolume removes the snapshot from the subvolume.
CleanupSnapshotFromSubvolume(ctx context.Context, parentVol *SubVolume) error
// SetAllMetadata set all the metadata from arg parameters on Ssubvolume.
SetAllMetadata(parameters map[string]string) error
// UnsetAllMetadata unset all the metadata from arg keys on subvolume.
UnsetAllMetadata(keys []string) error
}
// subVolumeClient implements SubVolumeClient interface.