mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-14 02:43:36 +00:00
cleanup: move internal/rbd/errors.go to internal/rbd/errors pacakge
Signed-off-by: Praveen M <m.praveen@ibm.com>
This commit is contained in:
@ -23,6 +23,7 @@ import (
|
||||
|
||||
csicommon "github.com/ceph/ceph-csi/internal/csi-common"
|
||||
rbdutil "github.com/ceph/ceph-csi/internal/rbd"
|
||||
rbderrors "github.com/ceph/ceph-csi/internal/rbd/errors"
|
||||
"github.com/ceph/ceph-csi/internal/util"
|
||||
"github.com/ceph/ceph-csi/internal/util/log"
|
||||
|
||||
@ -84,7 +85,7 @@ func (rscs *ReclaimSpaceControllerServer) ControllerReclaimSpace(
|
||||
defer rbdVol.Destroy(ctx)
|
||||
|
||||
err = rbdVol.Sparsify(ctx)
|
||||
if errors.Is(err, rbdutil.ErrImageInUse) {
|
||||
if errors.Is(err, rbderrors.ErrImageInUse) {
|
||||
// FIXME: https://github.com/csi-addons/kubernetes-csi-addons/issues/406.
|
||||
// treat sparsify call as no-op if volume is in use.
|
||||
log.DebugLog(ctx, fmt.Sprintf("volume with ID %q is in use, skipping sparsify operation", volumeID))
|
||||
|
Reference in New Issue
Block a user