diff --git a/akanda/neutron/extensions/_authzbase.py b/akanda/neutron/extensions/_authzbase.py index 5b05b7c..b3c30e7 100644 --- a/akanda/neutron/extensions/_authzbase.py +++ b/akanda/neutron/extensions/_authzbase.py @@ -16,11 +16,12 @@ import abc -from neutron import quota from neutron.api.v2 import base from neutron.api.v2 import resource as api_resource from neutron.common import exceptions as q_exc from neutron.common.config import cfg +from neutron.quota import resource as quota_resource +from neutron.quota import resource_registry class ResourcePlugin(object): @@ -187,7 +188,7 @@ def register_quota(resource_name, config_key_name, default=-1): help=('number of %s allowed per tenant, -1 for ' 'unlimited' % resource_name)) cfg.CONF.register_opts([quota_opt], 'QUOTAS') - quota.QUOTAS.register_resource( - quota.CountableResource(resource_name, - quota._count_resource, - config_key_name)) + + q_resource = quota_resource.CountableResource( + resource_name, quota_resource._count_resource, config_key_name) + resource_registry.register_resource(q_resource) diff --git a/requirements.txt b/requirements.txt index 4a4bc27..e4fb3a9 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,2 +1,5 @@ -oslo.log>=1.2.0 # Apache-2.0 -oslo.utils>=1.6.0 # Apache-2.0 +# The order of packages is significant, because pip processes them in the order +# of appearance. Changing the order has an impact on the overall integration +# process, which may cause wedges in the gate later. +oslo.log>=1.6.0 # Apache-2.0 +oslo.utils>=1.9.0 # Apache-2.0 diff --git a/setup.cfg b/setup.cfg index 449db6e..802b463 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = akanda-neutron -version = 2015.1 +version = 2015.2 summary = Akanda API extensions for OpenStack Neutron description-file = README.md diff --git a/setup.py b/setup.py index b9afb4f..d8080d0 100644 --- a/setup.py +++ b/setup.py @@ -1,23 +1,29 @@ -# Copyright 2014 DreamHost, LLC -# Copyright 2015 Akanda, Inc +# Copyright (c) 2013 Hewlett-Packard Development Company, L.P. # -# Author: DreamHost, LLC +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at # -# Licensed under the Apache License, Version 2.0 (the "License"); you may -# not use this file except in compliance with the License. You may obtain -# a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 +# http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT -# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the -# License for the specific language governing permissions and limitations -# under the License. - +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or +# implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# THIS FILE IS MANAGED BY THE GLOBAL REQUIREMENTS REPO - DO NOT EDIT import setuptools +# In python < 2.7.4, a lazy loading of package `pbr` will break +# setuptools if some other modules registered functions in `atexit`. +# solution from: http://bugs.python.org/issue15881#msg170215 +try: + import multiprocessing # noqa +except ImportError: + pass + setuptools.setup( - setup_requires=['pbr'], + setup_requires=['pbr>=1.3'], pbr=True)