cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yas...@apache.org
Subject [1/2] git commit: updated refs/heads/master to a21a4e5
Date Sat, 25 May 2013 00:12:25 GMT
Updated Branches:
  refs/heads/master a1437ae82 -> a21a4e5ac


CLOUDSTACK-2681: Suppress failed to apply port forwarding rule error when rollback


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/e3a32867
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/e3a32867
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/e3a32867

Branch: refs/heads/master
Commit: e3a32867586bbcebe04b009755bfcc116eb1a296
Parents: a1437ae
Author: Sheng Yang <sheng.yang@citrix.com>
Authored: Fri May 24 17:08:31 2013 -0700
Committer: Sheng Yang <sheng.yang@citrix.com>
Committed: Fri May 24 17:08:31 2013 -0700

----------------------------------------------------------------------
 .../user/firewall/CreatePortForwardingRuleCmd.java |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/e3a32867/api/src/org/apache/cloudstack/api/command/user/firewall/CreatePortForwardingRuleCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/firewall/CreatePortForwardingRuleCmd.java
b/api/src/org/apache/cloudstack/api/command/user/firewall/CreatePortForwardingRuleCmd.java
index 4012852..549de76 100644
--- a/api/src/org/apache/cloudstack/api/command/user/firewall/CreatePortForwardingRuleCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/firewall/CreatePortForwardingRuleCmd.java
@@ -198,7 +198,11 @@ public class CreatePortForwardingRuleCmd extends BaseAsyncCreateCmd implements
P
                     _firewallService.revokeRelatedFirewallRule(getEntityId(), true);
                 }
 
-                _rulesService.revokePortForwardingRule(getEntityId(), true);
+                try {
+                    _rulesService.revokePortForwardingRule(getEntityId(), true);
+                } catch (Exception ex){
+                    //Ignore e.g. failed to apply rules to device error
+                }
 
                 throw new ServerApiException(ApiErrorCode.INTERNAL_ERROR, "Failed to apply
port forwarding rule");
             }


Mime
View raw message