diff --git a/controllers/drplacementcontrol.go b/controllers/drplacementcontrol.go index 19f2d6de3..fe438dd1b 100644 --- a/controllers/drplacementcontrol.go +++ b/controllers/drplacementcontrol.go @@ -1204,7 +1204,7 @@ func (d *DRPCInstance) switchToCluster(targetCluster, targetClusterNamespace str vrgState = vrg.Status.State } - d.log.Info(fmt.Sprintf("PVs/PVCs have been Restored? %v and VRG Primary %v", restored, vrgState)) + d.log.Info(fmt.Sprintf("PVs/PVCs have been Restored? '%v' and VRG Primary='%v'", restored, vrgState)) if !restored || vrg.Status.State != rmn.PrimaryState { d.setProgression(rmn.ProgressionWaitingForResourceRestore) @@ -1987,7 +1987,7 @@ func (d *DRPCInstance) ensureVRGDeleted(clusterName string) bool { } func (d *DRPCInstance) updateVRGState(clusterName string, state rmn.ReplicationState) (bool, error) { - d.log.Info(fmt.Sprintf("Updating VRG ReplicationState to secondary for cluster %s", clusterName)) + d.log.Info(fmt.Sprintf("Updating VRG ReplicationState to %s for cluster %s", state, clusterName)) vrg, err := d.getVRGFromManifestWork(clusterName) if err != nil { diff --git a/controllers/util/mw_util.go b/controllers/util/mw_util.go index 51196e899..4753d32c6 100644 --- a/controllers/util/mw_util.go +++ b/controllers/util/mw_util.go @@ -532,6 +532,7 @@ func (mwu *MWUtil) createOrUpdateManifestWork( func (mwu *MWUtil) GetVRGManifestWorkCount(drClusters []string) int { count := 0 + for _, clusterName := range drClusters { _, err := mwu.FindManifestWorkByType(MWTypeVRG, clusterName) if err != nil {