cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yas...@apache.org
Subject git commit: updated refs/heads/master to 2b1b435
Date Sat, 15 Feb 2014 03:40:24 GMT
Repository: cloudstack
Updated Branches:
  refs/heads/master cc8eebeca -> 2b1b4352b


Revert "CLOUDSTACK-5779: Fix missing clean up period for VR"

This reverts commit 161e7d93ca9d03e9aa7e7be9e12d1ad337de9b14.

Duplicate code, bad memory...


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

Branch: refs/heads/master
Commit: 2b1b4352bc6af037430cff76b38d3eca061de0f7
Parents: cc8eebe
Author: Sheng Yang <sheng.yang@citrix.com>
Authored: Fri Feb 14 19:38:32 2014 -0800
Committer: Sheng Yang <sheng.yang@citrix.com>
Committed: Fri Feb 14 19:40:00 2014 -0800

----------------------------------------------------------------------
 .../virtualnetwork/VirtualRoutingResource.java  | 62 ++++++++------------
 1 file changed, 26 insertions(+), 36 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/2b1b4352/core/src/com/cloud/agent/resource/virtualnetwork/VirtualRoutingResource.java
----------------------------------------------------------------------
diff --git a/core/src/com/cloud/agent/resource/virtualnetwork/VirtualRoutingResource.java
b/core/src/com/cloud/agent/resource/virtualnetwork/VirtualRoutingResource.java
index a5647bc..9ecbe7f 100755
--- a/core/src/com/cloud/agent/resource/virtualnetwork/VirtualRoutingResource.java
+++ b/core/src/com/cloud/agent/resource/virtualnetwork/VirtualRoutingResource.java
@@ -138,69 +138,59 @@ public class VirtualRoutingResource {
                 return new Answer(cmd, false, rc.getDetails());
             }
 
-            Answer answer;
             if (cmd instanceof SetPortForwardingRulesVpcCommand) {
-                answer = execute((SetPortForwardingRulesVpcCommand)cmd);
+                return execute((SetPortForwardingRulesVpcCommand)cmd);
             } else if (cmd instanceof SetPortForwardingRulesCommand) {
-                answer = execute((SetPortForwardingRulesCommand)cmd);
+                return execute((SetPortForwardingRulesCommand)cmd);
             } else if (cmd instanceof SetStaticRouteCommand) {
-                answer = execute((SetStaticRouteCommand)cmd);
+                return execute((SetStaticRouteCommand)cmd);
             } else if (cmd instanceof SetStaticNatRulesCommand) {
-                answer = execute((SetStaticNatRulesCommand)cmd);
+                return execute((SetStaticNatRulesCommand)cmd);
             } else if (cmd instanceof LoadBalancerConfigCommand) {
-                answer = execute((LoadBalancerConfigCommand)cmd);
+                return execute((LoadBalancerConfigCommand)cmd);
             } else if (cmd instanceof SavePasswordCommand) {
-                answer = execute((SavePasswordCommand)cmd);
+                return execute((SavePasswordCommand)cmd);
             } else if (cmd instanceof DhcpEntryCommand) {
-                answer = execute((DhcpEntryCommand)cmd);
+                return execute((DhcpEntryCommand)cmd);
             } else if (cmd instanceof CreateIpAliasCommand) {
-                answer = execute((CreateIpAliasCommand)cmd);
+                return execute((CreateIpAliasCommand)cmd);
             } else if (cmd instanceof DnsMasqConfigCommand) {
-                answer = execute((DnsMasqConfigCommand)cmd);
+                return execute((DnsMasqConfigCommand)cmd);
             } else if (cmd instanceof DeleteIpAliasCommand) {
-                answer = execute((DeleteIpAliasCommand)cmd);
+                return execute((DeleteIpAliasCommand)cmd);
             } else if (cmd instanceof VmDataCommand) {
-                answer = execute((VmDataCommand)cmd);
+                return execute((VmDataCommand)cmd);
             } else if (cmd instanceof CheckRouterCommand) {
-                answer = execute((CheckRouterCommand)cmd);
+                return execute((CheckRouterCommand)cmd);
             } else if (cmd instanceof SetFirewallRulesCommand) {
-                answer = execute((SetFirewallRulesCommand)cmd);
+                return execute((SetFirewallRulesCommand)cmd);
             } else if (cmd instanceof BumpUpPriorityCommand) {
-                answer = execute((BumpUpPriorityCommand)cmd);
+                return execute((BumpUpPriorityCommand)cmd);
             } else if (cmd instanceof RemoteAccessVpnCfgCommand) {
-                answer = execute((RemoteAccessVpnCfgCommand)cmd);
+                return execute((RemoteAccessVpnCfgCommand)cmd);
             } else if (cmd instanceof VpnUsersCfgCommand) {
-                answer = execute((VpnUsersCfgCommand)cmd);
+                return execute((VpnUsersCfgCommand)cmd);
             } else if (cmd instanceof GetDomRVersionCmd) {
-                answer = execute((GetDomRVersionCmd)cmd);
+                return execute((GetDomRVersionCmd)cmd);
             } else if (cmd instanceof Site2SiteVpnCfgCommand) {
-                answer = execute((Site2SiteVpnCfgCommand)cmd);
+                return execute((Site2SiteVpnCfgCommand)cmd);
             } else if (cmd instanceof CheckS2SVpnConnectionsCommand) {
-                answer = execute((CheckS2SVpnConnectionsCommand)cmd);
+                return execute((CheckS2SVpnConnectionsCommand)cmd);
             } else if (cmd instanceof SetMonitorServiceCommand) {
-                answer = execute((SetMonitorServiceCommand)cmd);
+                return execute((SetMonitorServiceCommand)cmd);
             } else if (cmd instanceof SetupGuestNetworkCommand) {
-                answer = execute((SetupGuestNetworkCommand)cmd);
+                return execute((SetupGuestNetworkCommand)cmd);
             } else if (cmd instanceof SetNetworkACLCommand) {
-                answer = execute((SetNetworkACLCommand)cmd);
+                return execute((SetNetworkACLCommand)cmd);
             } else if (cmd instanceof SetSourceNatCommand) {
-                answer = execute((SetSourceNatCommand)cmd);
+                return execute((SetSourceNatCommand)cmd);
             } else if (cmd instanceof IpAssocVpcCommand) {
-                answer = execute((IpAssocVpcCommand)cmd);
+                return execute((IpAssocVpcCommand)cmd);
             } else if (cmd instanceof IpAssocCommand) {
-                answer = execute((IpAssocCommand)cmd);
+                return execute((IpAssocCommand)cmd);
             } else {
-                answer = Answer.createUnsupportedCommandAnswer(cmd);
+                return Answer.createUnsupportedCommandAnswer(cmd);
             }
-
-            rc = _vrDeployer.cleanupCommand((NetworkElementCommand)cmd);
-            if (!rc.isSuccess()) {
-                s_logger.error("Failed to clean up VR command due to " + rc.getDetails());
-                // TODO fail it more properly in the future, some commands may need specific
answer rather than generic answer
-                answer = new Answer(cmd, false, rc.getDetails());
-            }
-
-            return answer;
         } catch (final IllegalArgumentException e) {
             return new Answer(cmd, false, e.getMessage());
         } finally {


Mime
View raw message