Skip to content

Commit

Permalink
Check for Storage Class Present in Restore Cluster
Browse files Browse the repository at this point in the history
  • Loading branch information
pallav-px committed Oct 24, 2023
1 parent a5267e6 commit 70afc2b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/controllers/dataexport/reconcile.go
Original file line number Diff line number Diff line change
Expand Up @@ -917,6 +917,7 @@ func (c *Controller) stageSnapshotRestore(ctx context.Context, dataExport *kdmpa
pvc, err := c.restoreSnapshot(ctx, snapshotDriver, dataExport)
if err != nil {
msg := fmt.Sprintf("failed to restore a snapshot: %s", err)
logrus.Infof(" MESSAGE %s", msg)
data := updateDataExportDetail{
status: kdmpapi.DataExportStatusFailed,
reason: msg,
Expand Down Expand Up @@ -1623,6 +1624,8 @@ func (c *Controller) restoreSnapshot(ctx context.Context, snapshotDriver snapsho
return nil, err
}

logrus.Infof("Check for Storage Class %+v", srcPvc)

_, scErr := core.Instance().GetStorageClassForPVC(srcPvc)
if scErr != nil {
return nil, err
Expand Down

0 comments on commit 70afc2b

Please sign in to comment.