DK101010 commented on a change in pull request #5194:
URL: https://github.com/apache/cloudstack/pull/5194#discussion_r667654618



##########
File path: 
server/src/main/java/org/apache/cloudstack/vm/UnmanagedVMsManagerImpl.java
##########
@@ -617,8 +617,8 @@ private void 
checkUnmanagedNicAndNetworkForImport(UnmanagedInstanceTO.Nic nic, N
         }
         if (nic.getVlan() != null && nic.getVlan() != 0 && nic.getPvlan() != 
null && nic.getPvlan() != 0 &&
                 (Strings.isNullOrEmpty(network.getBroadcastUri().toString()) ||
-                        
!networkBroadcastUri.equals(String.format("pvlan://%d-i%d", nic.getVlan(), 
nic.getPvlan())))) {
-            throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, 
String.format("PVLAN of network(ID: %s) %s is found different from the VLAN of 
nic(ID: %s) pvlan://%d-i%d during VM import", network.getUuid(), 
networkBroadcastUri, nic.getNicId(), nic.getVlan(), nic.getPvlan()));
+                        
!networkBroadcastUri.equals(String.format("pvlan://%d-%s%d", nic.getVlan(), 
nic.getPvlanType().charAt(0), nic.getPvlan())))) {

Review comment:
       Hi @shwstppr yes, the types community and isolated are lowercase. I'm 
not quite sure if this will continue in the future. But I also didn't want to 
create pointless source code. That's why I left out for now
   
   
    




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