Skip to content

Commit bb18dd0

Browse files
committed
fix cmd param order
Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
1 parent f0d478f commit bb18dd0

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

server/src/main/java/org/apache/cloudstack/vm/VmImportManagerImpl.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -304,10 +304,6 @@ public UserVmResponse importUnmanagedInstance(ImportUnmanageInstanceCmd cmd) {
304304
if (cluster == null) {
305305
throw new InvalidParameterValueException(String.format("Cluster ID: %d cannot be found!", clusterId));
306306
}
307-
final Map<String, String> details = cmd.getDetails();
308-
final Map<String, String> nicIpAddressMap = cmd.getNicIpAddressList();
309-
final Map<String, Long> nicNetworkMap = cmd.getNicNetworkList();
310-
final Map<String, Long> dataDiskOfferingMap = cmd.getDataDiskToDiskOfferingList();
311307
if (cluster.getHypervisorType() != Hypervisor.HypervisorType.VMware) {
312308
throw new InvalidParameterValueException(String.format("VM ingestion is currently not supported for hypervisor: %s", cluster.getHypervisorType().toString()));
313309
}
@@ -363,8 +359,9 @@ public UserVmResponse importUnmanagedInstance(ImportUnmanageInstanceCmd cmd) {
363359
+ "and the hyphen ('-'), must be between 1 and 63 characters long, and can't start or end with \"-\" and can't start with digit");
364360
}
365361

366-
// final Map<String, Long> nicNetworkMap = cmd.getNicNetworkList();
367-
// final Map<String, Long> dataDiskOfferingMap = cmd.getDataDiskToDiskOfferingList();
362+
final Map<String, Long> nicNetworkMap = cmd.getNicNetworkList();
363+
final Map<String, String> nicIpAddressMap = cmd.getNicIpAddressList();
364+
final Map<String, Long> dataDiskOfferingMap = cmd.getDataDiskToDiskOfferingList();
368365

369366
List<HostVO> hosts = resourceManager.listHostsInClusterByStatus(clusterId, Status.Up);
370367

0 commit comments

Comments
 (0)