sureshanaparti commented on code in PR #12970:
URL: https://github.com/apache/cloudstack/pull/12970#discussion_r3055508484


##########
server/src/main/java/org/apache/cloudstack/vm/UnmanagedVMsManagerImpl.java:
##########
@@ -1684,9 +1695,16 @@ protected UserVm 
importUnmanagedInstanceFromVmwareToKvm(DataCenter zone, Cluster
         String ovfTemplateOnConvertLocation = null;
         ImportVmTask importVMTask = null;
         try {
-            HostVO convertHost = 
selectKVMHostForConversionInCluster(destinationCluster, convertInstanceHostId);
-            HostVO importHost = 
selectKVMHostForImportingInCluster(destinationCluster, importInstanceHostId);
-            CheckConvertInstanceAnswer conversionSupportAnswer = 
checkConversionSupportOnHost(convertHost, sourceVMName, false);
+            HostVO convertHost = 
selectKVMHostForConversionInCluster(destinationCluster, convertInstanceHostId, 
useVddk);
+            HostVO importHost = (useVddk && importInstanceHostId == null)
+                    ? convertHost
+                    : selectKVMHostForImportingInCluster(destinationCluster, 
importInstanceHostId);
+
+            boolean isOvfExportSupported = false;
+            if (!useVddk) {
+                CheckConvertInstanceAnswer conversionSupportAnswer = 
checkConversionSupportOnHost(convertHost, sourceVMName, false);

Review Comment:
   can add conversion support check for vddk as well? if convert host is from 
the api cmd and it doesn't support vddk, fail early.
   
   auto selection of convert host (when convert host is not passed from the api 
cmd) should return null and no hosts with vddk support.



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

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to