From 8c9105f09e6a618f1d573b031bcf516c5e8c7935 Mon Sep 17 00:00:00 2001 From: Madhu Rajanna Date: Mon, 20 Dec 2021 20:50:04 +0530 Subject: [PATCH] rbd: remove extra getImageInfo API call as getImageInfo is already called inside cloneRbdImageFromSnapshot function right after creating the clone. remove the extra API call to get the details again. Signed-off-by: Madhu Rajanna --- internal/rbd/snapshot.go | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/internal/rbd/snapshot.go b/internal/rbd/snapshot.go index f15f41db1..62191666b 100644 --- a/internal/rbd/snapshot.go +++ b/internal/rbd/snapshot.go @@ -64,17 +64,6 @@ func createRBDClone( return err } - err = cloneRbdVol.getImageInfo() - if err != nil { - log.ErrorLog(ctx, "failed to get rbd image: %s details with error: %v", cloneRbdVol, err) - delErr := deleteImage(ctx, cloneRbdVol, cr) - if delErr != nil { - log.ErrorLog(ctx, "failed to delete rbd image: %s with error: %v", cloneRbdVol, delErr) - } - - return err - } - return nil }