Skip to content

Commit cea53fb

Browse files
Prevent renaming VMware cluster as it could cause problems.
1 parent 91961eb commit cea53fb

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

server/src/main/java/com/cloud/resource/ResourceManagerImpl.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1039,6 +1039,9 @@ public Cluster updateCluster(UpdateClusterCmd cmd) {
10391039
boolean doUpdate = false;
10401040

10411041
if (org.apache.commons.lang.StringUtils.isNotBlank(name)) {
1042+
if(cluster.getHypervisorType() == HypervisorType.VMware) {
1043+
throw new InvalidParameterValueException(String.format("Renaming VMware cluster is not supported as it could cause a problem if the cluster on VCenter is not mapped."));
1044+
}
10421045
s_logger.debug("Updating Cluster name to: " + name);
10431046
cluster.setName(name);
10441047
doUpdate = true;

0 commit comments

Comments
 (0)