Merge pull request #4252 from nizamial09/difforchestration

ceph: added a check for triggering the orchestration
This commit is contained in:
Sébastien Han authored and GitHub committed 2019-11-05 12:37:26 +01:00
commit fab0646209
1 file changed
+5 -3
+5 -3
View File
@@ -335,11 +335,13 @@ func clusterChanged(oldCluster, newCluster cephv1.ClusterSpec, clusterRef *clust
// resource.Quantity has non-exportable fields, so we use its comparator method
resourceQtyComparer := cmp.Comparer(func(x, y resource.Quantity) bool { return x.Cmp(y) == 0 })
diff = cmp.Diff(oldCluster, newCluster, resourceQtyComparer)
logger.Infof("The Cluster CR has changed. diff=%s", diff)
}()
return true, diff
}
if diff != "" {
logger.Infof("The Cluster CR has changed. diff=%s", diff)
return true, diff
}
}
return false, ""
}