incubator-cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alena1...@apache.org
Subject [7/16] git commit: VPC: CS-15354 - fixed updateNetworkServiceProvider for VpcVirtualRouter
Date Tue, 26 Jun 2012 04:01:13 GMT
VPC: CS-15354 - fixed updateNetworkServiceProvider for VpcVirtualRouter


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

Branch: refs/heads/vpc
Commit: 4e7b65ef711bde232dc5657150f3d77de5dc291e
Parents: 4eee924
Author: Alena Prokharchyk <alena.prokharchyk@citrix.com>
Authored: Mon Jun 25 11:31:53 2012 -0700
Committer: Alena Prokharchyk <alena.prokharchyk@citrix.com>
Committed: Mon Jun 25 20:57:37 2012 -0700

----------------------------------------------------------------------
 .../network/element/VirtualRouterElement.java      |   10 ++++++++--
 .../network/element/VpcVirtualRouterElement.java   |    6 ++++++
 2 files changed, 14 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/4e7b65ef/server/src/com/cloud/network/element/VirtualRouterElement.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/network/element/VirtualRouterElement.java b/server/src/com/cloud/network/element/VirtualRouterElement.java
index 0feaa98..d0b9046 100755
--- a/server/src/com/cloud/network/element/VirtualRouterElement.java
+++ b/server/src/com/cloud/network/element/VirtualRouterElement.java
@@ -711,7 +711,8 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl
 
     @Override
     public boolean isReady(PhysicalNetworkServiceProvider provider) {
-        VirtualRouterProviderVO element = _vrProviderDao.findByNspIdAndType(provider.getId(),
VirtualRouterProviderType.VirtualRouter);
+        VirtualRouterProviderVO element = _vrProviderDao.findByNspIdAndType(provider.getId(),

+                getVirtualRouterProvider());
         if (element == null) {
             return false;
         }
@@ -722,7 +723,8 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl
     public boolean shutdownProviderInstances(PhysicalNetworkServiceProvider provider, ReservationContext
context) 
             throws ConcurrentOperationException,
             ResourceUnavailableException {
-        VirtualRouterProviderVO element = _vrProviderDao.findByNspIdAndType(provider.getId(),
VirtualRouterProviderType.VirtualRouter);
+        VirtualRouterProviderVO element = _vrProviderDao.findByNspIdAndType(provider.getId(),

+                getVirtualRouterProvider());
         if (element == null) {
             return true;
         }
@@ -874,4 +876,8 @@ public class VirtualRouterElement extends AdapterBase implements VirtualRouterEl
     public IpDeployer getIpDeployer(Network network) {
         return this;
     }
+    
+    protected VirtualRouterProviderType getVirtualRouterProvider() {
+        return VirtualRouterProviderType.VirtualRouter;
+    }
 }

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/4e7b65ef/server/src/com/cloud/network/element/VpcVirtualRouterElement.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/network/element/VpcVirtualRouterElement.java b/server/src/com/cloud/network/element/VpcVirtualRouterElement.java
index 563f5ef..dcd1218 100644
--- a/server/src/com/cloud/network/element/VpcVirtualRouterElement.java
+++ b/server/src/com/cloud/network/element/VpcVirtualRouterElement.java
@@ -32,6 +32,7 @@ import com.cloud.network.Network;
 import com.cloud.network.Network.Capability;
 import com.cloud.network.Network.Provider;
 import com.cloud.network.Network.Service;
+import com.cloud.network.VirtualRouterProvider.VirtualRouterProviderType;
 import com.cloud.network.NetworkService;
 import com.cloud.network.PublicIpAddress;
 import com.cloud.network.router.VirtualRouter;
@@ -395,4 +396,9 @@ public class VpcVirtualRouterElement extends VirtualRouterElement implements
Vpc
             return true;
         }
     }
+    
+    @Override
+    protected VirtualRouterProviderType getVirtualRouterProvider() {
+        return VirtualRouterProviderType.VPCVirtualRouter;
+    }
 }


Mime
View raw message