mirror of https://github.com/apache/cloudstack.git
VPC: one more fix for multiple public nic case for the VPC VR
Conflicts: server/test/com/cloud/network/MockNetworkManagerImpl.java
This commit is contained in:
parent
5a64d4fbb1
commit
2b7ec3f4a8
|
|
@ -386,9 +386,9 @@ public interface NetworkManager extends NetworkService {
|
|||
|
||||
/**
|
||||
* @param vm
|
||||
* @param network
|
||||
* @param nic TODO
|
||||
*/
|
||||
void removeNic(VirtualMachineProfile<? extends VMInstanceVO> vm, Network network);
|
||||
void removeNic(VirtualMachineProfile<? extends VMInstanceVO> vm, Nic nic);
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -2501,9 +2501,8 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService, Manag
|
|||
}
|
||||
|
||||
@Override
|
||||
public void removeNic(VirtualMachineProfile<? extends VMInstanceVO> vm, Network network) {
|
||||
NicVO nic = _nicDao.findByInstanceIdAndNetworkId(network.getId(), vm.getVirtualMachine().getId());
|
||||
removeNic(vm, nic);
|
||||
public void removeNic(VirtualMachineProfile<? extends VMInstanceVO> vm, Nic nic) {
|
||||
removeNic(vm, _nicDao.findById(nic.getId()));
|
||||
}
|
||||
|
||||
protected void removeNic(VirtualMachineProfile<? extends VMInstanceVO> vm, NicVO nic) {
|
||||
|
|
|
|||
|
|
@ -2552,7 +2552,7 @@ public class VirtualMachineManagerImpl implements VirtualMachineManager, Listene
|
|||
s_logger.debug("Successfully released nic " + nic + "for vm " + vm);
|
||||
|
||||
//3) Remove the nic
|
||||
_networkMgr.removeNic(vmProfile, network);
|
||||
_networkMgr.removeNic(vmProfile, nic);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -803,15 +803,6 @@ public class MockNetworkManagerImpl implements NetworkManager, Manager, NetworkS
|
|||
return null;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see com.cloud.network.NetworkManager#removeNic(com.cloud.vm.VirtualMachineProfile, com.cloud.network.Network)
|
||||
*/
|
||||
@Override
|
||||
public void removeNic(VirtualMachineProfile<? extends VMInstanceVO> vm, Network network) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see com.cloud.network.NetworkManager#listPublicIpsAssignedToAccount(long, long, java.lang.Boolean)
|
||||
*/
|
||||
|
|
@ -921,15 +912,6 @@ public class MockNetworkManagerImpl implements NetworkManager, Manager, NetworkS
|
|||
return null;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see com.cloud.network.NetworkManager#handleSystemIpRelease(com.cloud.network.IpAddress)
|
||||
*/
|
||||
@Override
|
||||
public boolean handleSystemIpRelease(IpAddress ip) {
|
||||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see com.cloud.network.NetworkManager#checkNetworkPermissions(com.cloud.user.Account, com.cloud.network.Network)
|
||||
*/
|
||||
|
|
@ -1138,4 +1120,22 @@ public class MockNetworkManagerImpl implements NetworkManager, Manager, NetworkS
|
|||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see com.cloud.network.NetworkManager#handleSystemIpRelease(com.cloud.network.IpAddress)
|
||||
*/
|
||||
@Override
|
||||
public boolean handleSystemIpRelease(IpAddress ip) {
|
||||
// TODO Auto-generated method stub
|
||||
return false;
|
||||
}
|
||||
|
||||
/* (non-Javadoc)
|
||||
* @see com.cloud.network.NetworkManager#removeNic(com.cloud.vm.VirtualMachineProfile, com.cloud.vm.Nic)
|
||||
*/
|
||||
@Override
|
||||
public void removeNic(VirtualMachineProfile<? extends VMInstanceVO> vm, Nic nic) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue