From c43afe3b7383ce93fef9cdd1ebb18de5dda0044a Mon Sep 17 00:00:00 2001 From: Bruce Ashfield Date: Fri, 20 Feb 2015 15:41:06 -0500 Subject: bbappends: resync to oe-core versions Updating the bbappends to match the oe-core versions ~commit 530565c6cb77319f4cc49edeea6fec6be997415d Signed-off-by: Bruce Ashfield --- .../fix_novaclient_memory_leak.patch | 105 --------------------- ...ent-specify-full-path-to-test-certificate.patch | 32 ------- 2 files changed, 137 deletions(-) delete mode 100644 meta-openstack/recipes-devtools/python/python-novaclient/fix_novaclient_memory_leak.patch delete mode 100644 meta-openstack/recipes-devtools/python/python-novaclient/novaclient-specify-full-path-to-test-certificate.patch (limited to 'meta-openstack/recipes-devtools/python/python-novaclient') diff --git a/meta-openstack/recipes-devtools/python/python-novaclient/fix_novaclient_memory_leak.patch b/meta-openstack/recipes-devtools/python/python-novaclient/fix_novaclient_memory_leak.patch deleted file mode 100644 index 37688d6..0000000 --- a/meta-openstack/recipes-devtools/python/python-novaclient/fix_novaclient_memory_leak.patch +++ /dev/null @@ -1,105 +0,0 @@ ---- - novaclient/client.py | 10 ++++++++++ - novaclient/openstack/common/apiclient/client.py | 10 ++++++++++ - novaclient/v1_1/client.py | 6 ++++++ - novaclient/v3/client.py | 6 ++++++ - 4 files changed, 32 insertions(+) - -Index: git/novaclient/client.py -=================================================================== ---- git.orig/novaclient/client.py -+++ git/novaclient/client.py -@@ -266,6 +266,7 @@ - self.timeout = None - - self.times = [] # [("item", starttime, endtime), ...] -+ self.times_max_len = 200 - - self.management_url = self.bypass_url or None - self.auth_token = auth_token -@@ -328,6 +329,12 @@ - else: - return name, value - -+ def get_timings_max_len(self): -+ return self.times_max_len -+ -+ def set_timings_max_len(self, new_len): -+ self.times_max_len = new_len -+ - def http_log_req(self, method, url, kwargs): - if not self.http_log_debug: - return -@@ -441,6 +448,9 @@ - resp, body = self.request(url, method, **kwargs) - self.times.append(("%s %s" % (method, url), - start_time, time.time())) -+ # remove oldest items until we maintain max length -+ while len(self.times) > self.times_max_len: -+ del self.times[0] - return resp, body - - def _cs_request(self, url, method, **kwargs): -Index: git/novaclient/openstack/common/apiclient/client.py -=================================================================== ---- git.orig/novaclient/openstack/common/apiclient/client.py -+++ git/novaclient/openstack/common/apiclient/client.py -@@ -92,6 +92,7 @@ - self.user_agent = user_agent or self.user_agent - - self.times = [] # [("item", starttime, endtime), ...] -+ self.times_max_len = 200 - self.timings = timings - - # requests within the same session can reuse TCP connections from pool -@@ -144,6 +145,12 @@ - def reset_timings(self): - self.times = [] - -+ def get_timings_max_len(self): -+ return self.times_max_len -+ -+ def set_timings_max_len(self, new_len): -+ self.times_max_len = new_len -+ - def request(self, method, url, **kwargs): - """Send an http request with the specified characteristics. - -@@ -175,6 +182,9 @@ - if self.timings: - self.times.append(("%s %s" % (method, url), - start_time, time.time())) -+ # remove oldest items until we maintain max length -+ while len(self.times) > self.times_max_len: -+ del self.times[0] - self._http_log_resp(resp) - - if resp.status_code >= 400: -Index: git/novaclient/v1_1/client.py -=================================================================== ---- git.orig/novaclient/v1_1/client.py -+++ git/novaclient/v1_1/client.py -@@ -232,3 +232,9 @@ - credentials are wrong. - """ - self.client.authenticate() -+ -+ def get_timings_max_len(self): -+ return self.client.get_timings_max_len() -+ -+ def set_timings_max_len(self, new_len): -+ self.client.set_timings_max_len(new_len) -Index: git/novaclient/v3/client.py -=================================================================== ---- git.orig/novaclient/v3/client.py -+++ git/novaclient/v3/client.py -@@ -194,3 +194,9 @@ - credentials are wrong. - """ - self.client.authenticate() -+ -+ def get_timings_max_len(self): -+ return self.client.get_timings_max_len() -+ -+ def set_timings_max_len(self, new_len): -+ self.client.set_timings_max_len(new_len) diff --git a/meta-openstack/recipes-devtools/python/python-novaclient/novaclient-specify-full-path-to-test-certificate.patch b/meta-openstack/recipes-devtools/python/python-novaclient/novaclient-specify-full-path-to-test-certificate.patch deleted file mode 100644 index 1cee4d0..0000000 --- a/meta-openstack/recipes-devtools/python/python-novaclient/novaclient-specify-full-path-to-test-certificate.patch +++ /dev/null @@ -1,32 +0,0 @@ -From bdd853d38c7b14088d3e6368e298201c249ab004 Mon Sep 17 00:00:00 2001 -From: Keith Holman -Date: Fri, 13 Jun 2014 09:54:41 -0400 -Subject: [PATCH] novaclient: specify full path to test certificate - -The tests shipped with novaclient assume that the files -exist at the same location as are appear within the -source tree. The tests also assume that the test is ran -from the root of the tree. This causes a test to fail as -it can't find a test certificate used in one of the -tests. This patch fixes the affected test by putting in -an identifier that is replaced with the full path to the -certificate file. - -Signed-off-by: Keith Holman ---- - novaclient/tests/v1_1/test_servers.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -Index: git/novaclient/tests/v1_1/test_servers.py -=================================================================== ---- git.orig/novaclient/tests/v1_1/test_servers.py -+++ git/novaclient/tests/v1_1/test_servers.py -@@ -501,7 +501,7 @@ - def test_get_password(self): - s = self.cs.servers.get(1234) - self.assertEqual(b'FooBar123', -- s.get_password('novaclient/tests/idfake.pem')) -+ s.get_password('%PYTHON_SITEPACKAGES_DIR%/novaclient/tests/idfake.pem')) - self.assert_called('GET', '/servers/1234/os-server-password') - - def test_get_password_without_key(self): -- cgit v1.2.3-54-g00ecf