mirror of https://github.com/apache/cloudstack.git
ignore unassignIPFromVpcNetwork in finally block of EnableStaticNat
unassignIPFromVpcNetwork processing should not execute when EnableStaticNat succeed. Without this patch, unassignIPFromVpcNetwork will execute whenever EnableStaticNat is successful or failed Reviewed-by: https://reviews.apache.org/r/9443/ Signed-off-by: Prasanna Santhanam <tsp@apache.org>
This commit is contained in:
parent
2dff2a85f3
commit
0ec4217aae
|
|
@ -471,6 +471,7 @@ public class RulesManagerImpl implements RulesManager, RulesService, Manager {
|
|||
// enable static nat on the backend
|
||||
s_logger.trace("Enabling static nat for ip address " + ipAddress + " and vm id=" + vmId + " on the backend");
|
||||
if (applyStaticNatForIp(ipId, false, caller, false)) {
|
||||
performedIpAssoc = false; // ignore unassignIPFromVpcNetwork in finally block
|
||||
return true;
|
||||
} else {
|
||||
s_logger.warn("Failed to enable static nat rule for ip address " + ipId + " on the backend");
|
||||
|
|
|
|||
Loading…
Reference in New Issue