You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by al...@apache.org on 2012/06/28 19:25:07 UTC

[6/12] git commit: VPC: don't generate empty SetStaticRoute command during VR start when there are no static routes for the VPC

VPC: don't generate empty SetStaticRoute command during VR start when there are no static routes for the VPC

Conflicts:

	server/src/com/cloud/user/AccountManagerImpl.java


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

Branch: refs/heads/vpc
Commit: 5ecdad73990dd9c4371c5d01f2ae25b26b177c4a
Parents: 09bd4e1
Author: Alena Prokharchyk <al...@citrix.com>
Authored: Wed Jun 27 10:31:15 2012 -0700
Committer: Alena Prokharchyk <al...@citrix.com>
Committed: Thu Jun 28 10:17:34 2012 -0700

----------------------------------------------------------------------
 .../VpcVirtualNetworkApplianceManagerImpl.java     |    4 +++-
 server/src/com/cloud/user/AccountManagerImpl.java  |    4 ++--
 2 files changed, 5 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/5ecdad73/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java b/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java
index d19a81e..f3ae3c9 100644
--- a/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java
+++ b/server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java
@@ -810,7 +810,9 @@ public class VpcVirtualNetworkApplianceManagerImpl extends VirtualNetworkApplian
         
         s_logger.debug("Found " + staticRouteProfiles.size() + " static routes to apply as a part of vpc route " 
                 + router + " start");
-        createStaticRouteCommands(staticRouteProfiles, router, cmds);
+        if (!staticRouteProfiles.isEmpty()) {   
+            createStaticRouteCommands(staticRouteProfiles, router, cmds);
+        }
         
         //4) REPROGRAM GUEST NETWORK
         boolean reprogramGuestNtwks = true;

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/5ecdad73/server/src/com/cloud/user/AccountManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/user/AccountManagerImpl.java b/server/src/com/cloud/user/AccountManagerImpl.java
index 8cc79bc..6c7aa95 100755
--- a/server/src/com/cloud/user/AccountManagerImpl.java
+++ b/server/src/com/cloud/user/AccountManagerImpl.java
@@ -599,8 +599,8 @@ public class AccountManagerImpl implements AccountManager, AccountService, Manag
                 for (IpAddress ip : ipsToRelease) {
                     s_logger.debug("Releasing ip " + ip + " as a part of account id=" + accountId + " cleanup");
                     if (!_networkMgr.disassociatePublicIpAddress(ip.getId(), callerUserId, caller)) {
-                        s_logger.warn("Failed to release ip address " + ip + " as a part of account id=" + accountId + " clenaup");
-                        accountCleanupNeeded = true;
+                    s_logger.warn("Failed to release ip address " + ip + " as a part of account id=" + accountId + " clenaup");
+                    accountCleanupNeeded = true;
                     }
                 }
             }