GabrielBrascher commented on a change in pull request #4779:
URL: https://github.com/apache/cloudstack/pull/4779#discussion_r590470584



##########
File path: server/src/main/java/com/cloud/capacity/CapacityManagerImpl.java
##########
@@ -665,11 +665,10 @@ public void updateCapacityForHost(final Host host, final 
Map<Long, ServiceOfferi
             Map<String, String> vmDetails = 
_userVmDetailsDao.listDetailsKeyPairs(vm.getId());
             String vmDetailCpu = vmDetails.get("cpuOvercommitRatio");
             String vmDetailRam = vmDetails.get("memoryOvercommitRatio");
-            if (vmDetailCpu != null) {
-                //if vmDetail_cpu is not null it means it is running in a 
overcommited cluster.
-                cpuOvercommitRatio = Float.parseFloat(vmDetailCpu);
-                ramOvercommitRatio = Float.parseFloat(vmDetailRam);
-            }
+            //if vmDetail_cpu is not null it means it is running in a 
overcommitted cluster.

Review comment:
       My only suggestion would be to merge these two comments into one, at 
line 668.
   Example:
   ```
   //if vmDetailCpu or vmDetailRam is not null it means it is running in an 
overcommitted cluster.
   ```




----------------------------------------------------------------
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]


Reply via email to