cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] mike-tutkowski commented on a change in pull request #2848: Vmware offline migration
Date Tue, 20 Nov 2018 21:05:28 GMT
mike-tutkowski commented on a change in pull request #2848: Vmware offline migration
URL: https://github.com/apache/cloudstack/pull/2848#discussion_r235164086
 
 

 ##########
 File path: api/src/main/java/org/apache/cloudstack/api/command/admin/vm/MigrateVMCmd.java
 ##########
 @@ -119,13 +119,7 @@ public String getEventType() {
 
     @Override
     public String getEventDescription() {
-        if (getHostId() != null) {
-            return "Attempting to migrate VM Id: " + this._uuidMgr.getUuid(VirtualMachine.class,
getVirtualMachineId()) + " to host Id: " + this._uuidMgr.getUuid(Host.class, getHostId());
-        } else if (getStoragePoolId() != null) {
-            return "Attempting to migrate VM Id: " + this._uuidMgr.getUuid(VirtualMachine.class,
getVirtualMachineId()) + " to storage pool Id: " + this._uuidMgr.getUuid(StoragePool.class,
getStoragePoolId());
-        } else {
-            return "Attempting to migrate VM Id: " + this._uuidMgr.getUuid(VirtualMachine.class,
getVirtualMachineId());
-        }
+        return "Attempting to migrate VM Id: " + getVirtualMachineId() + " to host Id: "
+ getHostId();
 
 Review comment:
   Were the two other if statement just never executed because this is the MigrateVMCmd, which
should only be migrating a VM from one host to another (i.e. no storage migration)?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message