diff options
-rw-r--r-- | doc/requirements.txt | 6 | ||||
-rwxr-xr-x | doc/source/conf.py | 6 | ||||
-rw-r--r-- | lower-constraints.txt | 5 | ||||
-rw-r--r-- | oslo_rootwrap/client.py | 14 | ||||
-rw-r--r-- | releasenotes/source/conf.py | 6 | ||||
-rw-r--r-- | test-requirements.txt | 2 |
6 files changed, 21 insertions, 18 deletions
diff --git a/doc/requirements.txt b/doc/requirements.txt index 625782d..625ec03 100644 --- a/doc/requirements.txt +++ b/doc/requirements.txt @@ -2,9 +2,9 @@ # of appearance. Changing the order has an impact on the overall integration # process, which may cause wedges in the gate later. # These are needed for docs generation -openstackdocstheme>=1.20.0 # Apache-2.0 -sphinx>=1.8.0,!=2.1.0 # BSD -reno>=2.5.0 # Apache-2.0 +openstackdocstheme>=2.2.0 # Apache-2.0 +sphinx>=2.0.0,!=2.1.0 # BSD +reno>=3.1.0 # Apache-2.0 mock>=2.0.0 # BSD fixtures>=3.0.0 # Apache-2.0/BSD diff --git a/doc/source/conf.py b/doc/source/conf.py index 171ad87..e32b4b0 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -27,9 +27,9 @@ extensions = [ ] # openstackdocstheme options -repository_name = 'openstack/oslo.rootwrap' -bug_project = 'oslo.rootwrap' -bug_tag = '' +openstackdocs_repo_name = 'openstack/oslo.rootwrap' +openstackdocs_bug_project = 'oslo.rootwrap' +openstackdocs_bug_tag = '' # autodoc generation is a bit aggressive and a nuisance when doing heavy # text edit cycles. diff --git a/lower-constraints.txt b/lower-constraints.txt index 41a3230..dbee9da 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -17,7 +17,6 @@ keystoneauth1==3.4.0 linecache2==1.0.0 MarkupSafe==1.0 mox3==0.20.0 -openstackdocstheme==1.20.0 os-client-config==1.28.0 oslotest==3.2.0 pbr==2.0.0 @@ -26,14 +25,12 @@ python-mimeparse==1.6.0 python-subunit==1.0.0 pytz==2013.6 PyYAML==3.12 -reno==2.5.0 +reno==3.1.0 requests==2.14.2 requestsexceptions==1.2.0 six==1.10.0 smmap==0.9.0 snowballstemmer==1.2.1 -Sphinx==1.8.0 -sphinxcontrib-websupport==1.0.1 stestr==2.0.0 stevedore==1.20.0 testtools==2.2.0 diff --git a/oslo_rootwrap/client.py b/oslo_rootwrap/client.py index 0dd0742..a607be3 100644 --- a/oslo_rootwrap/client.py +++ b/oslo_rootwrap/client.py @@ -17,6 +17,7 @@ import logging from multiprocessing import managers from multiprocessing import util as mp_util import threading +import time import weakref import oslo_rootwrap @@ -41,6 +42,7 @@ except AttributeError: ClientManager = daemon.get_manager_class() LOG = logging.getLogger(__name__) +SHUTDOWN_RETRIES = 3 class Client(object): @@ -108,10 +110,14 @@ class Client(object): if process.poll() is None: LOG.info('Stopping rootwrap daemon process with pid=%s', process.pid) - try: - manager.rootwrap().shutdown() - except (EOFError, IOError): - pass # assume it is dead already + for _ in range(SHUTDOWN_RETRIES): + try: + manager.rootwrap().shutdown() + break + except (EOFError, IOError): + break # assume it is dead already + except RuntimeError: + time.sleep(0.2) # We might want to wait for process to exit or kill it, but we # can't provide sane timeout on 2.x and we most likely don't have # permisions to do so diff --git a/releasenotes/source/conf.py b/releasenotes/source/conf.py index de6b5ff..f619b50 100644 --- a/releasenotes/source/conf.py +++ b/releasenotes/source/conf.py @@ -40,9 +40,9 @@ extensions = [ ] # openstackdocstheme options -repository_name = 'openstack/oslo.rootwrap' -bug_project = 'oslo.rootwrap' -bug_tag = '' +openstackdocs_repo_name = 'openstack/oslo.rootwrap' +openstackdocs_bug_project = 'oslo.rootwrap' +openstackdocs_bug_tag = '' # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] diff --git a/test-requirements.txt b/test-requirements.txt index 4a129a5..bea15d4 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -14,7 +14,7 @@ oslotest>=3.2.0 # Apache-2.0 # rootwrap daemon's client should be verified to run in eventlet eventlet!=0.18.3,!=0.20.1,>=0.18.2 # MIT -reno>=2.5.0 # Apache-2.0 +reno>=3.1.0 # Apache-2.0 # Bandit security code scanner bandit>=1.1.0 # Apache-2.0 |