Migrate to oslo.concurrency

Namespaces are not used anymore, so imports are for oslo_concurrency,
not oslo.concurrency.

lockutils direct call is not supported anymore, so using shipped
lockutils-wrapper instead.

Closes-Bug: #1387092
Change-Id: I2ba2295f8f5d55f272a9d23555940586b25b5a1c
This commit is contained in:
Ihar Hrachyshka 2015-01-14 17:39:43 +01:00
parent 506ecb5189
commit 88e2d801d5
5 changed files with 7 additions and 6 deletions

View File

@ -17,12 +17,12 @@ import requests
from oslo.config import cfg from oslo.config import cfg
from oslo import messaging from oslo import messaging
from oslo_concurrency import lockutils
from neutron.common import exceptions from neutron.common import exceptions
from neutron.common import rpc as n_rpc from neutron.common import rpc as n_rpc
from neutron import context as ctx from neutron import context as ctx
from neutron.i18n import _LE, _LI, _LW from neutron.i18n import _LE, _LI, _LW
from neutron.openstack.common import lockutils
from neutron.openstack.common import log as logging from neutron.openstack.common import log as logging
from neutron.openstack.common import loopingcall from neutron.openstack.common import loopingcall
from neutron.plugins.common import constants from neutron.plugins.common import constants

View File

@ -22,6 +22,7 @@ import jinja2
import netaddr import netaddr
from oslo.config import cfg from oslo.config import cfg
from oslo import messaging from oslo import messaging
from oslo_concurrency import lockutils
import six import six
from neutron.agent.linux import ip_lib from neutron.agent.linux import ip_lib
@ -29,7 +30,6 @@ from neutron.agent.linux import utils
from neutron.common import rpc as n_rpc from neutron.common import rpc as n_rpc
from neutron import context from neutron import context
from neutron.i18n import _LE from neutron.i18n import _LE
from neutron.openstack.common import lockutils
from neutron.openstack.common import log as logging from neutron.openstack.common import log as logging
from neutron.openstack.common import loopingcall from neutron.openstack.common import loopingcall
from neutron.plugins.common import constants from neutron.plugins.common import constants

View File

@ -9,6 +9,7 @@ netaddr>=0.7.12
SQLAlchemy>=0.9.7,<=0.9.99 SQLAlchemy>=0.9.7,<=0.9.99
alembic>=0.7.1 alembic>=0.7.1
six>=1.7.0 six>=1.7.0
oslo.concurrency>=0.3.0,!=0.4.0
oslo.config>=1.6.0 # Apache-2.0 oslo.config>=1.6.0 # Apache-2.0
oslo.db>=1.3.0 # Apache-2.0 oslo.db>=1.3.0 # Apache-2.0
oslo.messaging>=1.4.0,!=1.5.0 oslo.messaging>=1.4.0,!=1.5.0

View File

@ -3,4 +3,4 @@
TESTRARGS=$1 TESTRARGS=$1
exec 3>&1 exec 3>&1
status=$(exec 4>&1 >&3; ( python -m neutron.openstack.common.lockutils python setup.py testr --slowest --testr-args="--subunit $TESTRARGS"; echo $? >&4 ) | $(dirname $0)/subunit-trace.py -f) && exit $status status=$(exec 4>&1 >&3; ( lockutils-wrapper python setup.py testr --slowest --testr-args="--subunit $TESTRARGS"; echo $? >&4 ) | $(dirname $0)/subunit-trace.py -f) && exit $status

View File

@ -28,7 +28,7 @@ setenv = VIRTUAL_ENV={envdir}
[testenv:functional] [testenv:functional]
setenv = OS_TEST_PATH=./neutron-vpnaas/tests/functional setenv = OS_TEST_PATH=./neutron-vpnaas/tests/functional
commands = commands =
python -m neutron_vpnaas.openstack.common.lockutils python setup.py testr --slowest --testr-args='{posargs}' lockutils-wrapper python setup.py testr --slowest --testr-args='{posargs}'
[testenv:dsvm-functional] [testenv:dsvm-functional]
setenv = OS_TEST_PATH=./neutron_vpnaas/tests/functional setenv = OS_TEST_PATH=./neutron_vpnaas/tests/functional
@ -37,7 +37,7 @@ setenv = OS_TEST_PATH=./neutron_vpnaas/tests/functional
OS_FAIL_ON_MISSING_DEPS=1 OS_FAIL_ON_MISSING_DEPS=1
sitepackages=True sitepackages=True
commands = commands =
python -m neutron_vpnaas.openstack.common.lockutils python setup.py testr --slowest --testr-args='{posargs}' lockutils-wrapper python setup.py testr --slowest --testr-args='{posargs}'
[tox:jenkins] [tox:jenkins]
sitepackages = True sitepackages = True
@ -56,7 +56,7 @@ commands = python ./tools/check_i18n.py ./neutron-vpnaas ./tools/i18n_cfg.py
[testenv:cover] [testenv:cover]
commands = commands =
python -m neutron.openstack.common.lockutils python setup.py testr --coverage --testr-args='{posargs}' lockutils-wrapper python setup.py testr --coverage --testr-args='{posargs}'
[testenv:venv] [testenv:venv]
commands = {posargs} commands = {posargs}