GabrielBrascher commented on a change in pull request #4165:
URL: https://github.com/apache/cloudstack/pull/4165#discussion_r456028267
##########
File path: server/src/main/java/com/cloud/resource/ResourceManagerImpl.java
##########
@@ -1026,12 +1027,26 @@ public void doInTransactionWithoutResult(final
TransactionStatus status) {
@Override
@DB
- public Cluster updateCluster(final Cluster clusterToUpdate, final String
clusterType, final String hypervisor, final String allocationState, final
String managedstate) {
+ public Cluster updateCluster(UpdateClusterCmd cmd) {
+ ClusterVO cluster = (ClusterVO) getCluster(cmd.getId());
+ String clusterType = cmd.getClusterType();
+ String hypervisor = cmd.getHypervisor();
+ String allocationState = cmd.getAllocationState();
+ String managedstate = cmd.getManagedstate();
+ String name = cmd.getClusterName();
- final ClusterVO cluster = (ClusterVO)clusterToUpdate;
// Verify cluster information and update the cluster if needed
boolean doUpdate = false;
+ if (org.apache.commons.lang.StringUtils.isNotBlank(name)) {
+ if(cluster.getHypervisorType() == HypervisorType.VMware) {
Review comment:
@rhtyd considering your concerns with issues caused by renaming VMware
clusters I added this line.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]