From deb003e605add47dbac91c416888c371b2e3ad5b Mon Sep 17 00:00:00 2001 From: Prasanna Kumar Kalever Date: Mon, 11 Apr 2022 15:29:58 +0530 Subject: [PATCH] cleanup: use prefix instead of hardcoding csiParameterPrefix Signed-off-by: Prasanna Kumar Kalever --- internal/util/k8s/parameters.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/internal/util/k8s/parameters.go b/internal/util/k8s/parameters.go index 2306bcafd..f212e3915 100644 --- a/internal/util/k8s/parameters.go +++ b/internal/util/k8s/parameters.go @@ -26,14 +26,14 @@ const ( // PV and PVC metadata keys used by external provisioner as part of // create requests as parameters, when `extra-create-metadata` is true. - pvcNameKey = "csi.storage.k8s.io/pvc/name" - pvcNamespaceKey = "csi.storage.k8s.io/pvc/namespace" - pvNameKey = "csi.storage.k8s.io/pv/name" + pvcNameKey = csiParameterPrefix + "pvc/name" + pvcNamespaceKey = csiParameterPrefix + "pvc/namespace" + pvNameKey = csiParameterPrefix + "pv/name" // snapshot metadata keys. - volSnapNameKey = "csi.storage.k8s.io/volumesnapshot/name" - volSnapNamespaceKey = "csi.storage.k8s.io/volumesnapshot/namespace" - volSnapContentNameKey = "csi.storage.k8s.io/volumesnapshotcontent/name" + volSnapNameKey = csiParameterPrefix + "volumesnapshot/name" + volSnapNamespaceKey = csiParameterPrefix + "volumesnapshot/namespace" + volSnapContentNameKey = csiParameterPrefix + "volumesnapshotcontent/name" ) // RemoveCSIPrefixedParameters removes parameters prefixed with csiParameterPrefix.