cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r...@apache.org
Subject [05/11] git commit: updated refs/heads/master to c9922ea
Date Mon, 18 Jan 2016 11:13:40 GMT
CLOUDSTACK-9187 - Makes code ready for more something like ethXXXX, if we ever get that far

   - Adds log info to NetworkOrchestrator in order to make the work of the Net-Scavenger more
visible.


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

Branch: refs/heads/master
Commit: f5a6dee8dd6b89ef954d39b4ade91f8f898cc026
Parents: 2aab4c1
Author: Wilder Rodrigues <wrodrigues@schubergphilis.com>
Authored: Fri Dec 18 20:18:24 2015 +0100
Committer: Wilder Rodrigues <wrodrigues@schubergphilis.com>
Committed: Tue Dec 22 14:52:07 2015 +0100

----------------------------------------------------------------------
 .../engine/orchestration/NetworkOrchestrator.java      |  6 +++++-
 .../debian/config/opt/cloud/bin/cs/CsAddress.py        | 10 ++++++----
 test/integration/smoke/test_vpc_redundant.py           | 13 +++++--------
 3 files changed, 16 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f5a6dee8/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/NetworkOrchestrator.java
----------------------------------------------------------------------
diff --git a/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/NetworkOrchestrator.java
b/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/NetworkOrchestrator.java
index ca465ef..5f442b3 100644
--- a/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/NetworkOrchestrator.java
+++ b/engine/orchestration/src/org/apache/cloudstack/engine/orchestration/NetworkOrchestrator.java
@@ -586,6 +586,8 @@ public class NetworkOrchestrator extends ManagerBase implements NetworkOrchestra
     @Override
     public boolean start() {
         final int netGcInterval = NumbersUtil.parseInt(_configDao.getValue(NetworkGcInterval.key()),
60);
+        s_logger.info("Network Manager will run the NetworkGarbageCollector every '" + netGcInterval
+ "' seconds.");
+
         _executor.scheduleWithFixedDelay(new NetworkGarbageCollector(), netGcInterval, netGcInterval,
TimeUnit.SECONDS);
         return true;
     }
@@ -2445,7 +2447,9 @@ public class NetworkOrchestrator extends ManagerBase implements NetworkOrchestra
                 final HashMap<Long, Long> stillFree = new HashMap<Long, Long>();
 
                 final List<Long> networkIds = _networksDao.findNetworksToGarbageCollect();
-                final int netGcWait = NumbersUtil.parseInt(_configDao.getValue(NetworkGcWait.key()),
1);
+                final int netGcWait = NumbersUtil.parseInt(_configDao.getValue(NetworkGcWait.key()),
60);
+                s_logger.info("NetworkGarbageCollector uses '" + netGcWait + "' seconds for
GC interval.");
+
                 for (final Long networkId : networkIds) {
 
                     if (!_networkModel.isNetworkReadyForGc(networkId)) {

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f5a6dee8/systemvm/patches/debian/config/opt/cloud/bin/cs/CsAddress.py
----------------------------------------------------------------------
diff --git a/systemvm/patches/debian/config/opt/cloud/bin/cs/CsAddress.py b/systemvm/patches/debian/config/opt/cloud/bin/cs/CsAddress.py
index 3eb9447..1b39b38 100755
--- a/systemvm/patches/debian/config/opt/cloud/bin/cs/CsAddress.py
+++ b/systemvm/patches/debian/config/opt/cloud/bin/cs/CsAddress.py
@@ -51,13 +51,15 @@ class CsAddress(CsDataBag):
         Return CsInterface object for the lowest in use guest interface
         """
         guest_interface = None
-        lowest_device = 99
+        lowest_device = 1000
         for ip in self.get_ips():
             if ip.is_guest() and ip.is_added():
-                devive_sufix = int(ip.get_device()[-1:])
-                if devive_sufix < lowest_device:
-                    lowest_device = devive_sufix
+                device = ip.get_device()
+                device_suffix = int(''.join([digit for digit in device if digit.isdigit()]))
+                if device_suffix < lowest_device:
+                    lowest_device = device_suffix
                     guest_interface = ip
+                    logging.debug("Guest interface will be set on device '%s' and IP '%s'"
% (guest_interface.get_device(), guest_interface.get_ip()))
         return guest_interface
 
     def get_guest_ip(self):

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/f5a6dee8/test/integration/smoke/test_vpc_redundant.py
----------------------------------------------------------------------
diff --git a/test/integration/smoke/test_vpc_redundant.py b/test/integration/smoke/test_vpc_redundant.py
index 2ffc938..65797e8 100644
--- a/test/integration/smoke/test_vpc_redundant.py
+++ b/test/integration/smoke/test_vpc_redundant.py
@@ -523,8 +523,7 @@ class TestVPCRedundancy(cloudstackTestCase):
                 self.fail("Failed to SSH into VM - %s" % (public_ip.ipaddress.ipaddress))
 
     @attr(tags=["advanced", "intervlan"], required_hardware="true")
-    def test_04_create_redundant_VPC_2tiers_4VMs_4IPs_4PF_ACL(self):
-        self.skipTest("Skipping for now...")
+    def test_01_create_redundant_VPC_2tiers_4VMs_4IPs_4PF_ACL(self):
         """ Create a redundant VPC with two networks with two VMs in each network """
         self.logger.debug("Starting test_01_create_redundant_VPC_2tiers_4VMs_4IPs_4PF_ACL")
         self.query_routers()
@@ -549,8 +548,7 @@ class TestVPCRedundancy(cloudstackTestCase):
         self.do_vpc_test(False)
 
     @attr(tags=["advanced", "intervlan"], required_hardware="true")
-    def test_05_redundant_VPC_default_routes(self):
-        self.skipTest("Skipping for now...")
+    def test_02_redundant_VPC_default_routes(self):
         """ Create a redundant VPC with two networks with two VMs in each network and check
default routes"""
         self.logger.debug("Starting test_02_redundant_VPC_default_routes")
         self.query_routers()
@@ -562,7 +560,6 @@ class TestVPCRedundancy(cloudstackTestCase):
     
     @attr(tags=["advanced", "intervlan"], required_hardware="true")
     def test_03_create_redundant_VPC_1tier_2VMs_2IPs_2PF_ACL_reboot_routers(self):
-        self.skipTest("Skipping for now...")
         """ Create a redundant VPC with two networks with two VMs in each network """
         self.logger.debug("Starting test_01_create_redundant_VPC_2tiers_4VMs_4IPs_4PF_ACL")
         self.query_routers()
@@ -580,7 +577,7 @@ class TestVPCRedundancy(cloudstackTestCase):
         self.do_vpc_test(False)
 
     @attr(tags=["advanced", "intervlan"], required_hardware="true")
-    def test_01_rvpc_network_garbage_collector_nics(self):
+    def test_04_rvpc_network_garbage_collector_nics(self):
         """ Create a redundant VPC with 1 Tier, 1 VM, 1 ACL, 1 PF and test Network GC Nics"""
         self.logger.debug("Starting test_04_rvpc_network_garbage_collector_nics")
         self.query_routers()
@@ -597,7 +594,7 @@ class TestVPCRedundancy(cloudstackTestCase):
         self.logger.debug("network.gc.wait is ==> %s" % gc_wait)
         self.logger.debug("network.gc.interval is ==> %s" % gc_wait)
 
-        total_sleep = 90
+        total_sleep = 120
         if gc_wait and gc_interval:
             total_sleep = int(gc_wait[0].value) + int(gc_interval[0].value)
         else:
@@ -611,7 +608,7 @@ class TestVPCRedundancy(cloudstackTestCase):
         self.do_vpc_test(False)
 
     @attr(tags=["advanced", "intervlan"], required_hardware="true")
-    def test_02_rvpc_multi_tiers(self):
+    def test_05_rvpc_multi_tiers(self):
         """ Create a redundant VPC with 1 Tier, 1 VM, 1 ACL, 1 PF and test Network GC Nics"""
         self.logger.debug("Starting test_04_rvpc_network_garbage_collector_nics")
         self.query_routers()


Mime
View raw message