Browse Source

Rename v1_1 to v2

Module novaclient.v1_1 is used as implementation of V1.1, V2 and V3.
Since future development(microversioning) will be done across V2,
implementation should be done in appropriate module(to prevent misleading).

Despite the fact that implementation for all versions are equal, discover
method for contrib path worked only for v1.1. This patch fixes this bug and
modifies shell tests to check all versions.

Change-Id: Ib6798f4dfe177586302141f522dc593560ce6a5b
changes/06/149006/13
Andrey Kurilin 7 years ago
parent
commit
0a60aae852
  1. 4
      README.rst
  2. 3
      doc/source/api.rst
  3. 6
      doc/source/conf.py
  4. 3
      doc/source/index.rst
  5. 2
      doc/source/shell.rst
  6. 6
      novaclient/client.py
  7. 16
      novaclient/shell.py
  8. 12
      novaclient/tests/unit/fixture_data/client.py
  9. 2
      novaclient/tests/unit/test_auth_plugins.py
  10. 4
      novaclient/tests/unit/test_base.py
  11. 38
      novaclient/tests/unit/test_client.py
  12. 0
      novaclient/tests/unit/v2/__init__.py
  13. 0
      novaclient/tests/unit/v2/contrib/__init__.py
  14. 4
      novaclient/tests/unit/v2/contrib/fakes.py
  15. 4
      novaclient/tests/unit/v2/contrib/test_assisted_volume_snapshots.py
  16. 4
      novaclient/tests/unit/v2/contrib/test_baremetal.py
  17. 4
      novaclient/tests/unit/v2/contrib/test_cells.py
  18. 4
      novaclient/tests/unit/v2/contrib/test_instance_actions.py
  19. 4
      novaclient/tests/unit/v2/contrib/test_list_extensions.py
  20. 4
      novaclient/tests/unit/v2/contrib/test_migrations.py
  21. 4
      novaclient/tests/unit/v2/contrib/test_server_external_events.py
  22. 4
      novaclient/tests/unit/v2/contrib/test_tenant_networks.py
  23. 2
      novaclient/tests/unit/v2/fakes.py
  24. 2
      novaclient/tests/unit/v2/test_agents.py
  25. 2
      novaclient/tests/unit/v2/test_aggregates.py
  26. 2
      novaclient/tests/unit/v2/test_auth.py
  27. 4
      novaclient/tests/unit/v2/test_availability_zone.py
  28. 2
      novaclient/tests/unit/v2/test_certs.py
  29. 2
      novaclient/tests/unit/v2/test_client.py
  30. 2
      novaclient/tests/unit/v2/test_cloudpipe.py
  31. 0
      novaclient/tests/unit/v2/test_fixed_ips.py
  32. 4
      novaclient/tests/unit/v2/test_flavor_access.py
  33. 4
      novaclient/tests/unit/v2/test_flavors.py
  34. 2
      novaclient/tests/unit/v2/test_floating_ip_dns.py
  35. 2
      novaclient/tests/unit/v2/test_floating_ip_pools.py
  36. 2
      novaclient/tests/unit/v2/test_floating_ips.py
  37. 2
      novaclient/tests/unit/v2/test_floating_ips_bulk.py
  38. 2
      novaclient/tests/unit/v2/test_fping.py
  39. 2
      novaclient/tests/unit/v2/test_hosts.py
  40. 0
      novaclient/tests/unit/v2/test_hypervisors.py
  41. 2
      novaclient/tests/unit/v2/test_images.py
  42. 2
      novaclient/tests/unit/v2/test_keypairs.py
  43. 2
      novaclient/tests/unit/v2/test_limits.py
  44. 2
      novaclient/tests/unit/v2/test_networks.py
  45. 2
      novaclient/tests/unit/v2/test_quota_classes.py
  46. 0
      novaclient/tests/unit/v2/test_quotas.py
  47. 2
      novaclient/tests/unit/v2/test_security_group_rules.py
  48. 2
      novaclient/tests/unit/v2/test_security_groups.py
  49. 2
      novaclient/tests/unit/v2/test_server_groups.py
  50. 2
      novaclient/tests/unit/v2/test_servers.py
  51. 4
      novaclient/tests/unit/v2/test_services.py
  52. 52
      novaclient/tests/unit/v2/test_shell.py
  53. 4
      novaclient/tests/unit/v2/test_usage.py
  54. 4
      novaclient/tests/unit/v2/test_volumes.py
  55. 0
      novaclient/tests/unit/v2/testfile.txt
  56. 0
      novaclient/tests/unit/v2/utils.py
  57. 30
      novaclient/v1_1/__init__.py
  58. 16
      novaclient/v2/__init__.py
  59. 0
      novaclient/v2/agents.py
  60. 0
      novaclient/v2/aggregates.py
  61. 0
      novaclient/v2/availability_zones.py
  62. 0
      novaclient/v2/certs.py
  63. 66
      novaclient/v2/client.py
  64. 0
      novaclient/v2/cloudpipe.py
  65. 0
      novaclient/v2/contrib/__init__.py
  66. 0
      novaclient/v2/contrib/assisted_volume_snapshots.py
  67. 0
      novaclient/v2/contrib/baremetal.py
  68. 0
      novaclient/v2/contrib/cells.py
  69. 0
      novaclient/v2/contrib/deferred_delete.py
  70. 0
      novaclient/v2/contrib/host_evacuate.py
  71. 0
      novaclient/v2/contrib/host_evacuate_live.py
  72. 0
      novaclient/v2/contrib/host_servers_migrate.py
  73. 0
      novaclient/v2/contrib/instance_action.py
  74. 0
      novaclient/v2/contrib/list_extensions.py
  75. 2
      novaclient/v2/contrib/metadata_extensions.py
  76. 0
      novaclient/v2/contrib/migrations.py
  77. 0
      novaclient/v2/contrib/server_external_events.py
  78. 0
      novaclient/v2/contrib/tenant_networks.py
  79. 0
      novaclient/v2/fixed_ips.py
  80. 0
      novaclient/v2/flavor_access.py
  81. 0
      novaclient/v2/flavors.py
  82. 0
      novaclient/v2/floating_ip_dns.py
  83. 0
      novaclient/v2/floating_ip_pools.py
  84. 0
      novaclient/v2/floating_ips.py
  85. 0
      novaclient/v2/floating_ips_bulk.py
  86. 0
      novaclient/v2/fping.py
  87. 0
      novaclient/v2/hosts.py
  88. 0
      novaclient/v2/hypervisors.py
  89. 0
      novaclient/v2/images.py
  90. 0
      novaclient/v2/keypairs.py
  91. 0
      novaclient/v2/limits.py
  92. 0
      novaclient/v2/networks.py
  93. 0
      novaclient/v2/quota_classes.py
  94. 0
      novaclient/v2/quotas.py
  95. 0
      novaclient/v2/security_group_default_rules.py
  96. 0
      novaclient/v2/security_group_rules.py
  97. 0
      novaclient/v2/security_groups.py
  98. 0
      novaclient/v2/server_groups.py
  99. 2
      novaclient/v2/servers.py
  100. 0
      novaclient/v2/services.py

4
README.rst

@ -46,7 +46,7 @@ and the version of the API with ``--os-compute-api-version``. Or set them as
an environment variables as well::
export OS_AUTH_URL=http://example.com:8774/v1.1/
export OS_COMPUTE_API_VERSION=1.1
export OS_COMPUTE_API_VERSION=2
If you are using Keystone, you need to set the OS_AUTH_URL to the keystone
endpoint::
@ -69,7 +69,7 @@ There's also a complete Python API, but it has not yet been documented.
To use with nova, with keystone as the authentication system::
# use v2.0 auth with http://example.com:5000/v2.0/")
>>> from novaclient.v1_1 import client
>>> from novaclient.v2 import client
>>> nt = client.Client(USER, PASS, TENANT, AUTH_URL, service_type="compute")
>>> nt.flavors.list()
[...]

3
doc/source/api.rst

@ -60,5 +60,4 @@ For more information, see the reference:
:maxdepth: 2
ref/index
ref/v1_1/index
ref/v3/index
ref/v2/index

6
doc/source/conf.py

@ -71,17 +71,13 @@ def gen_ref(ver, title, names):
"pkg": pkg, "name": name})
gen_ref(None, "Exceptions", ["exceptions"])
gen_ref("v1_1", "Version 1.1, Version 2 API Reference",
gen_ref("v2", "Version 1.1, Version 2 API Reference, Version 3 API Reference",
["flavors", "images", "servers", "hosts", "agents", "aggregates",
"availability_zones", "certs", "fixed_ips", "floating_ip_pools",
"floating_ips", "hypervisors", "keypairs", "limits", "networks",
"quota_classes", "quotas", "security_group_rules",
"security_groups", "services", "virtual_interfaces",
"volume_snapshots", "volumes", "volume_types"])
gen_ref("v3", "Version 3 API Reference",
["flavors", "hosts", "agents", "aggregates", "availability_zones",
"certs", "hypervisors", "images", "keypairs", "quotas",
"quotas_classes", "servers", "services"])
# -- General configuration ----------------------------------------------------

3
doc/source/index.rst

@ -25,8 +25,7 @@ Contents:
shell
api
ref/index
ref/v1_1/index
ref/v3/index
ref/v2/index
releases
Contributing

2
doc/source/shell.rst

@ -41,7 +41,7 @@ For example, in Bash you'd use::
export OS_PASSWORD=yadayadayada
export OS_TENANT_NAME=myproject
export OS_AUTH_URL=http://...
export OS_COMPUTE_API_VERSION=1.1
export OS_COMPUTE_API_VERSION=2
From there, all shell commands take the form::

6
novaclient/client.py

@ -773,9 +773,9 @@ def _construct_http_client(username=None, password=None, project_id=None,
def get_client_class(version):
version_map = {
'1.1': 'novaclient.v1_1.client.Client',
'2': 'novaclient.v1_1.client.Client',
'3': 'novaclient.v1_1.client.Client',
'1.1': 'novaclient.v2.client.Client',
'2': 'novaclient.v2.client.Client',
'3': 'novaclient.v2.client.Client',
}
try:
client_path = version_map[str(version)]

16
novaclient/shell.py

@ -55,9 +55,9 @@ import novaclient.extension
from novaclient.i18n import _
from novaclient.openstack.common import cliutils
from novaclient import utils
from novaclient.v1_1 import shell as shell_v1_1
from novaclient.v2 import shell as shell_v2
DEFAULT_OS_COMPUTE_API_VERSION = "1.1"
DEFAULT_OS_COMPUTE_API_VERSION = "2"
DEFAULT_NOVA_ENDPOINT_TYPE = 'publicURL'
# NOTE(cyeoh): Having the service type dependent on the API version
# is pretty ugly, but we have to do this because traditionally the
@ -446,12 +446,12 @@ class OpenStackComputeShell(object):
try:
actions_module = {
'1.1': shell_v1_1,
'2': shell_v1_1,
'3': shell_v1_1,
'1.1': shell_v2,
'2': shell_v2,
'3': shell_v2,
}[version]
except KeyError:
actions_module = shell_v1_1
actions_module = shell_v2
self._find_actions(subparsers, actions_module)
self._find_actions(subparsers, self)
@ -491,6 +491,10 @@ class OpenStackComputeShell(object):
def _discover_via_contrib_path(self, version):
module_path = os.path.dirname(os.path.abspath(__file__))
version_str = "v%s" % version.replace('.', '_')
# NOTE(akurilin): v1.1, v2 and v3 have one implementation, so
# we should discover contrib modules in one place.
if version_str in ["v1_1", "v3"]:
version_str = "v2"
ext_path = os.path.join(module_path, version_str, 'contrib')
ext_glob = os.path.join(ext_path, "*.py")

12
novaclient/tests/unit/fixture_data/client.py

@ -15,7 +15,7 @@ from keystoneclient.auth.identity import v2
from keystoneclient import fixture
from keystoneclient import session
from novaclient.v1_1 import client as v1_1client
from novaclient.v2 import client as v2client
IDENTITY_URL = 'http://identityserver:5000/v2.0'
COMPUTE_URL = 'http://compute.host'
@ -51,10 +51,10 @@ class V1(fixtures.Fixture):
self.client = self.new_client()
def new_client(self):
return v1_1client.Client(username='xx',
api_key='xx',
project_id='xx',
auth_url=self.identity_url)
return v2client.Client(username='xx',
api_key='xx',
project_id='xx',
auth_url=self.identity_url)
class SessionV1(V1):
@ -62,4 +62,4 @@ class SessionV1(V1):
def new_client(self):
self.session = session.Session()
self.session.auth = v2.Password(self.identity_url, 'xx', 'xx')
return v1_1client.Client(session=self.session)
return v2client.Client(session=self.session)

2
novaclient/tests/unit/test_auth_plugins.py

@ -28,7 +28,7 @@ except ImportError:
from novaclient import auth_plugin
from novaclient import exceptions
from novaclient.tests.unit import utils
from novaclient.v1_1 import client
from novaclient.v2 import client
def mock_http_request(resp=None):

4
novaclient/tests/unit/test_base.py

@ -14,8 +14,8 @@
from novaclient import base
from novaclient import exceptions
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1 import flavors
from novaclient.tests.unit.v2 import fakes
from novaclient.v2 import flavors
cs = fakes.FakeClient()

38
novaclient/tests/unit/test_client.py

@ -24,7 +24,7 @@ import requests
import novaclient.client
import novaclient.extension
from novaclient.tests.unit import utils
import novaclient.v1_1.client
import novaclient.v2.client
class ClientConnectionPoolTest(utils.TestCase):
@ -138,57 +138,57 @@ class ClientTest(utils.TestCase):
def test_get_client_class_v3(self):
output = novaclient.client.get_client_class('3')
self.assertEqual(output, novaclient.v1_1.client.Client)
self.assertEqual(output, novaclient.v2.client.Client)
def test_get_client_class_v2(self):
output = novaclient.client.get_client_class('2')
self.assertEqual(output, novaclient.v1_1.client.Client)
self.assertEqual(output, novaclient.v2.client.Client)
def test_get_client_class_v2_int(self):
output = novaclient.client.get_client_class(2)
self.assertEqual(output, novaclient.v1_1.client.Client)
self.assertEqual(output, novaclient.v2.client.Client)
def test_get_client_class_v1_1(self):
output = novaclient.client.get_client_class('1.1')
self.assertEqual(output, novaclient.v1_1.client.Client)
self.assertEqual(output, novaclient.v2.client.Client)
def test_get_client_class_unknown(self):
self.assertRaises(novaclient.exceptions.UnsupportedVersion,
novaclient.client.get_client_class, '0')
def test_client_with_os_cache_enabled(self):
cs = novaclient.v1_1.client.Client("user", "password", "project_id",
auth_url="foo/v2", os_cache=True)
cs = novaclient.v2.client.Client("user", "password", "project_id",
auth_url="foo/v2", os_cache=True)
self.assertEqual(True, cs.os_cache)
self.assertEqual(True, cs.client.os_cache)
def test_client_with_os_cache_disabled(self):
cs = novaclient.v1_1.client.Client("user", "password", "project_id",
auth_url="foo/v2", os_cache=False)
cs = novaclient.v2.client.Client("user", "password", "project_id",
auth_url="foo/v2", os_cache=False)
self.assertEqual(False, cs.os_cache)
self.assertEqual(False, cs.client.os_cache)
def test_client_with_no_cache_enabled(self):
cs = novaclient.v1_1.client.Client("user", "password", "project_id",
auth_url="foo/v2", no_cache=True)
cs = novaclient.v2.client.Client("user", "password", "project_id",
auth_url="foo/v2", no_cache=True)
self.assertEqual(False, cs.os_cache)
self.assertEqual(False, cs.client.os_cache)
def test_client_with_no_cache_disabled(self):
cs = novaclient.v1_1.client.Client("user", "password", "project_id",
auth_url="foo/v2", no_cache=False)
cs = novaclient.v2.client.Client("user", "password", "project_id",
auth_url="foo/v2", no_cache=False)
self.assertEqual(True, cs.os_cache)
self.assertEqual(True, cs.client.os_cache)
def test_client_set_management_url_v1_1(self):
cs = novaclient.v1_1.client.Client("user", "password", "project_id",
auth_url="foo/v2")
cs = novaclient.v2.client.Client("user", "password", "project_id",
auth_url="foo/v2")
cs.set_management_url("blabla")
self.assertEqual("blabla", cs.client.management_url)
def test_client_get_reset_timings_v1_1(self):
cs = novaclient.v1_1.client.Client("user", "password", "project_id",
auth_url="foo/v2")
cs = novaclient.v2.client.Client("user", "password", "project_id",
auth_url="foo/v2")
self.assertEqual(0, len(cs.get_timings()))
cs.client.times.append("somevalue")
self.assertEqual(1, len(cs.get_timings()))
@ -201,8 +201,8 @@ class ClientTest(utils.TestCase):
def test_contextmanager_v1_1(self, mock_http_client):
fake_client = mock.Mock()
mock_http_client.return_value = fake_client
with novaclient.v1_1.client.Client("user", "password", "project_id",
auth_url="foo/v2"):
with novaclient.v2.client.Client("user", "password", "project_id",
auth_url="foo/v2"):
pass
self.assertTrue(fake_client.open_session.called)
self.assertTrue(fake_client.close_session.called)

0
novaclient/tests/unit/v1_1/__init__.py → novaclient/tests/unit/v2/__init__.py

0
novaclient/tests/unit/v1_1/contrib/__init__.py → novaclient/tests/unit/v2/contrib/__init__.py

4
novaclient/tests/unit/v1_1/contrib/fakes.py → novaclient/tests/unit/v2/contrib/fakes.py

@ -12,8 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1 import client
from novaclient.tests.unit.v2 import fakes
from novaclient.v2 import client
class FakeClient(fakes.FakeClient):

4
novaclient/tests/unit/v1_1/contrib/test_assisted_volume_snapshots.py → novaclient/tests/unit/v2/contrib/test_assisted_volume_snapshots.py

@ -18,8 +18,8 @@ Assisted volume snapshots - to be used by Cinder and not end users.
from novaclient import extension
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1.contrib import fakes
from novaclient.v1_1.contrib import assisted_volume_snapshots as assisted_snaps
from novaclient.tests.unit.v2.contrib import fakes
from novaclient.v2.contrib import assisted_volume_snapshots as assisted_snaps
extensions = [

4
novaclient/tests/unit/v1_1/contrib/test_baremetal.py → novaclient/tests/unit/v2/contrib/test_baremetal.py

@ -16,8 +16,8 @@
from novaclient import extension
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1.contrib import fakes
from novaclient.v1_1.contrib import baremetal
from novaclient.tests.unit.v2.contrib import fakes
from novaclient.v2.contrib import baremetal
extensions = [

4
novaclient/tests/unit/v1_1/contrib/test_cells.py → novaclient/tests/unit/v2/contrib/test_cells.py

@ -15,8 +15,8 @@
from novaclient import extension
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1.contrib import fakes
from novaclient.v1_1.contrib import cells
from novaclient.tests.unit.v2.contrib import fakes
from novaclient.v2.contrib import cells
extensions = [

4
novaclient/tests/unit/v1_1/contrib/test_instance_actions.py → novaclient/tests/unit/v2/contrib/test_instance_actions.py

@ -15,8 +15,8 @@
from novaclient import extension
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1.contrib import fakes
from novaclient.v1_1.contrib import instance_action
from novaclient.tests.unit.v2.contrib import fakes
from novaclient.v2.contrib import instance_action
extensions = [

4
novaclient/tests/unit/v1_1/contrib/test_list_extensions.py → novaclient/tests/unit/v2/contrib/test_list_extensions.py

@ -13,8 +13,8 @@
from novaclient import extension
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1.contrib import list_extensions
from novaclient.tests.unit.v2 import fakes
from novaclient.v2.contrib import list_extensions
extensions = [

4
novaclient/tests/unit/v1_1/contrib/test_migrations.py → novaclient/tests/unit/v2/contrib/test_migrations.py

@ -12,8 +12,8 @@
from novaclient import extension
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1.contrib import migrations
from novaclient.tests.unit.v2 import fakes
from novaclient.v2.contrib import migrations
extensions = [
extension.Extension(migrations.__name__.split(".")[-1],

4
novaclient/tests/unit/v1_1/contrib/test_server_external_events.py → novaclient/tests/unit/v2/contrib/test_server_external_events.py

@ -18,8 +18,8 @@ External event triggering for servers, not to be used by users.
from novaclient import extension
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1.contrib import fakes
from novaclient.v1_1.contrib import server_external_events as ext_events
from novaclient.tests.unit.v2.contrib import fakes
from novaclient.v2.contrib import server_external_events as ext_events
extensions = [

4
novaclient/tests/unit/v1_1/contrib/test_tenant_networks.py → novaclient/tests/unit/v2/contrib/test_tenant_networks.py

@ -15,8 +15,8 @@
from novaclient import extension
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1.contrib import fakes
from novaclient.v1_1.contrib import tenant_networks
from novaclient.tests.unit.v2.contrib import fakes
from novaclient.v2.contrib import tenant_networks
extensions = [

2
novaclient/tests/unit/v1_1/fakes.py → novaclient/tests/unit/v2/fakes.py

@ -25,7 +25,7 @@ from novaclient import client as base_client
from novaclient import exceptions
from novaclient.tests.unit import fakes
from novaclient.tests.unit import utils
from novaclient.v1_1 import client
from novaclient.v2 import client
class FakeClient(fakes.FakeClient, client.Client):

2
novaclient/tests/unit/v1_1/test_agents.py → novaclient/tests/unit/v2/test_agents.py

@ -16,7 +16,7 @@
from novaclient.tests.unit.fixture_data import agents as data
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit import utils
from novaclient.v1_1 import agents
from novaclient.v2 import agents
class AgentsTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_aggregates.py → novaclient/tests/unit/v2/test_aggregates.py

@ -16,7 +16,7 @@
from novaclient.tests.unit.fixture_data import aggregates as data
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit import utils
from novaclient.v1_1 import aggregates
from novaclient.v2 import aggregates
class AggregatesTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_auth.py → novaclient/tests/unit/v2/test_auth.py

@ -20,7 +20,7 @@ import requests
from novaclient import exceptions
from novaclient.tests.unit import utils
from novaclient.v1_1 import client
from novaclient.v2 import client
class AuthenticateAgainstKeystoneTests(utils.TestCase):

4
novaclient/tests/unit/v1_1/test_availability_zone.py → novaclient/tests/unit/v2/test_availability_zone.py

@ -19,13 +19,13 @@ import six
from novaclient.tests.unit.fixture_data import availability_zones as data
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit import utils
from novaclient.v1_1 import availability_zones
from novaclient.v2 import availability_zones
class AvailabilityZoneTest(utils.FixturedTestCase):
# NOTE(cyeoh): import shell here so the V3 version of
# this class can inherit off the v3 version of shell
from novaclient.v1_1 import shell # noqa
from novaclient.v2 import shell # noqa
data_fixture_class = data.V1

2
novaclient/tests/unit/v1_1/test_certs.py → novaclient/tests/unit/v2/test_certs.py

@ -14,7 +14,7 @@
from novaclient.tests.unit.fixture_data import certs as data
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit import utils
from novaclient.v1_1 import certs
from novaclient.v2 import certs
class CertsTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_client.py → novaclient/tests/unit/v2/test_client.py

@ -15,7 +15,7 @@ import uuid
from keystoneclient import session
from novaclient.tests.unit import utils
from novaclient.v1_1 import client
from novaclient.v2 import client
class ClientTest(utils.TestCase):

2
novaclient/tests/unit/v1_1/test_cloudpipe.py → novaclient/tests/unit/v2/test_cloudpipe.py

@ -16,7 +16,7 @@ import six
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import cloudpipe as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import cloudpipe
from novaclient.v2 import cloudpipe
class CloudpipeTest(utils.FixturedTestCase):

0
novaclient/tests/unit/v1_1/test_fixed_ips.py → novaclient/tests/unit/v2/test_fixed_ips.py

4
novaclient/tests/unit/v1_1/test_flavor_access.py → novaclient/tests/unit/v2/test_flavor_access.py

@ -14,8 +14,8 @@
# under the License.
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1 import flavor_access
from novaclient.tests.unit.v2 import fakes
from novaclient.v2 import flavor_access
cs = fakes.FakeClient()

4
novaclient/tests/unit/v1_1/test_flavors.py → novaclient/tests/unit/v2/test_flavors.py

@ -17,8 +17,8 @@ import mock
from novaclient import exceptions
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1 import flavors
from novaclient.tests.unit.v2 import fakes
from novaclient.v2 import flavors
class FlavorsTest(utils.TestCase):

2
novaclient/tests/unit/v1_1/test_floating_ip_dns.py → novaclient/tests/unit/v2/test_floating_ip_dns.py

@ -14,7 +14,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import floatingips as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import floating_ip_dns
from novaclient.v2 import floating_ip_dns
class FloatingIPDNSDomainTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_floating_ip_pools.py → novaclient/tests/unit/v2/test_floating_ip_pools.py

@ -17,7 +17,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import floatingips as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import floating_ip_pools
from novaclient.v2 import floating_ip_pools
class TestFloatingIPPools(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_floating_ips.py → novaclient/tests/unit/v2/test_floating_ips.py

@ -17,7 +17,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import floatingips as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import floating_ips
from novaclient.v2 import floating_ips
class FloatingIPsTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_floating_ips_bulk.py → novaclient/tests/unit/v2/test_floating_ips_bulk.py

@ -16,7 +16,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import floatingips as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import floating_ips_bulk
from novaclient.v2 import floating_ips_bulk
class FloatingIPsBulkTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_fping.py → novaclient/tests/unit/v2/test_fping.py

@ -16,7 +16,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import fping as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import fping
from novaclient.v2 import fping
class FpingTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_hosts.py → novaclient/tests/unit/v2/test_hosts.py

@ -14,7 +14,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import hosts as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import hosts
from novaclient.v2 import hosts
class HostsTest(utils.FixturedTestCase):

0
novaclient/tests/unit/v1_1/test_hypervisors.py → novaclient/tests/unit/v2/test_hypervisors.py

2
novaclient/tests/unit/v1_1/test_images.py → novaclient/tests/unit/v2/test_images.py

@ -14,7 +14,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import images as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import images
from novaclient.v2 import images
class ImagesTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_keypairs.py → novaclient/tests/unit/v2/test_keypairs.py

@ -14,7 +14,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import keypairs as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import keypairs
from novaclient.v2 import keypairs
class KeypairsTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_limits.py → novaclient/tests/unit/v2/test_limits.py

@ -14,7 +14,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import limits as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import limits
from novaclient.v2 import limits
class LimitsTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_networks.py → novaclient/tests/unit/v2/test_networks.py

@ -14,7 +14,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import networks as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import networks
from novaclient.v2 import networks
class NetworksTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_quota_classes.py → novaclient/tests/unit/v2/test_quota_classes.py

@ -14,7 +14,7 @@
# under the License.
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.tests.unit.v2 import fakes
cs = fakes.FakeClient()

0
novaclient/tests/unit/v1_1/test_quotas.py → novaclient/tests/unit/v2/test_quotas.py

2
novaclient/tests/unit/v1_1/test_security_group_rules.py → novaclient/tests/unit/v2/test_security_group_rules.py

@ -15,7 +15,7 @@ from novaclient import exceptions
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import security_group_rules as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import security_group_rules
from novaclient.v2 import security_group_rules
class SecurityGroupRulesTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_security_groups.py → novaclient/tests/unit/v2/test_security_groups.py

@ -14,7 +14,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import security_groups as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import security_groups
from novaclient.v2 import security_groups
class SecurityGroupsTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_server_groups.py → novaclient/tests/unit/v2/test_server_groups.py

@ -16,7 +16,7 @@
from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import server_groups as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import server_groups
from novaclient.v2 import server_groups
class ServerGroupsTest(utils.FixturedTestCase):

2
novaclient/tests/unit/v1_1/test_servers.py → novaclient/tests/unit/v2/test_servers.py

@ -21,7 +21,7 @@ from novaclient.tests.unit.fixture_data import client
from novaclient.tests.unit.fixture_data import floatingips
from novaclient.tests.unit.fixture_data import servers as data
from novaclient.tests.unit import utils
from novaclient.v1_1 import servers
from novaclient.v2 import servers
class ServersTest(utils.FixturedTestCase):

4
novaclient/tests/unit/v1_1/test_services.py → novaclient/tests/unit/v2/test_services.py

@ -14,8 +14,8 @@
# under the License.
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1 import services
from novaclient.tests.unit.v2 import fakes
from novaclient.v2 import services
class ServicesTest(utils.TestCase):

52
novaclient/tests/unit/v1_1/test_shell.py → novaclient/tests/unit/v2/test_shell.py

@ -30,8 +30,8 @@ import novaclient.client
from novaclient import exceptions
import novaclient.shell
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
import novaclient.v1_1.shell
from novaclient.tests.unit.v2 import fakes
import novaclient.v2.shell
class ShellFixture(fixtures.Fixture):
@ -54,7 +54,7 @@ class ShellTest(utils.TestCase):
'NOVA_USERNAME': 'username',
'NOVA_PASSWORD': 'password',
'NOVA_PROJECT_ID': 'project_id',
'OS_COMPUTE_API_VERSION': '1.1',
'OS_COMPUTE_API_VERSION': '2',
'NOVA_URL': 'http://no.where',
'OS_AUTH_URL': 'http://no.where/v2.0',
}
@ -644,7 +644,7 @@ class ShellTest(utils.TestCase):
cmd = 'boot --image 1 --flavor 1 --min-count 3 --max-count 1 serv'
self.assertRaises(exceptions.CommandError, self.run_command, cmd)
@mock.patch('novaclient.v1_1.shell._poll_for_status')
@mock.patch('novaclient.v2.shell._poll_for_status')
def test_boot_with_poll(self, poll_method):
self.run_command('boot --flavor 1 --image 1 some-server --poll')
self.assert_called_anytime(
@ -1088,7 +1088,7 @@ class ShellTest(utils.TestCase):
self.assertRaises(exceptions.CommandError,
self.run_command, 'show xxx')
@mock.patch('novaclient.v1_1.shell.utils.print_dict')
@mock.patch('novaclient.v2.shell.utils.print_dict')
def test_print_server(self, mock_print_dict):
self.run_command('show 5678')
args, kwargs = mock_print_dict.call_args
@ -2225,7 +2225,7 @@ class ShellTest(utils.TestCase):
'/os-migrations?cell_name=child1&host=host1'
'&status=finished')
@mock.patch('novaclient.v1_1.shell._find_server')
@mock.patch('novaclient.v2.shell._find_server')
@mock.patch('os.system')
def test_ssh(self, mock_system, mock_find_server):
class FakeResources(object):
@ -2273,7 +2273,7 @@ class ShellTest(utils.TestCase):
mock_system.assert_called_with("ssh -6 -p22 "
"root@2607:f0d0:1002::4 -1")
@mock.patch('novaclient.v1_1.shell._find_server')
@mock.patch('novaclient.v2.shell._find_server')
@mock.patch('os.system')
def test_ssh_multinet(self, mock_system, mock_find_server):
class FakeResources(object):
@ -2338,6 +2338,28 @@ class ShellTest(utils.TestCase):
self.assert_called('DELETE', '/os-server-groups/12345', pos=-2)
class ShellTestV11(ShellTest):
FAKE_ENV = {
'NOVA_USERNAME': 'username',
'NOVA_PASSWORD': 'password',
'NOVA_PROJECT_ID': 'project_id',
'OS_COMPUTE_API_VERSION': '1.1',
'NOVA_URL': 'http://no.where',
'OS_AUTH_URL': 'http://no.where/v2.0',
}
class ShellTestV3(ShellTest):
FAKE_ENV = {
'NOVA_USERNAME': 'username',
'NOVA_PASSWORD': 'password',
'NOVA_PROJECT_ID': 'project_id',
'OS_COMPUTE_API_VERSION': '3',
'NOVA_URL': 'http://no.where',
'OS_AUTH_URL': 'http://no.where/v2.0',
}
class ShellWithSessionClientTest(ShellTest):
def setUp(self):
@ -2354,7 +2376,7 @@ class GetSecgroupTest(utils.TestCase):
'security_groups.get.return_value': 'sec_group',
'security_groups.list.return_value': [],
})
result = novaclient.v1_1.shell._get_secgroup(cs, '1')
result = novaclient.v2.shell._get_secgroup(cs, '1')
self.assertEqual('sec_group', result)
cs.security_groups.get.assert_called_once_with('1')
@ -2363,7 +2385,7 @@ class GetSecgroupTest(utils.TestCase):
'security_groups.get.return_value': 'sec_group',
'security_groups.list.return_value': [],
})
result = novaclient.v1_1.shell._get_secgroup(
result = novaclient.v2.shell._get_secgroup(
cs, 'c0c32459-dc5f-44dc-9a0a-473b28bac831')
self.assertEqual('sec_group', result)
cs.security_groups.get.assert_called_once_with(
@ -2375,7 +2397,7 @@ class GetSecgroupTest(utils.TestCase):
'security_groups.list.return_value': [],
})
self.assertRaises(exceptions.CommandError,
novaclient.v1_1.shell._get_secgroup,
novaclient.v2.shell._get_secgroup,
cs,
'abc')
@ -2387,7 +2409,7 @@ class GetSecgroupTest(utils.TestCase):
'security_groups.list.return_value': [group_one, group_one],
})
self.assertRaises(exceptions.NoUniqueMatch,
novaclient.v1_1.shell._get_secgroup,
novaclient.v2.shell._get_secgroup,
cs,
'group_one')
@ -2396,7 +2418,7 @@ class GetFirstEndpointTest(utils.TestCase):
def test_only_one_endpoint(self):
"""If there is only one endpoint, it is returned."""
endpoint = {"url": "test"}
result = novaclient.v1_1.shell._get_first_endpoint([endpoint], "XYZ")
result = novaclient.v2.shell._get_first_endpoint([endpoint], "XYZ")
self.assertEqual(endpoint, result)
def test_multiple_endpoints(self):
@ -2409,7 +2431,7 @@ class GetFirstEndpointTest(utils.TestCase):
{"region": "ORD", "number": 1},
{"region": "ORD", "number": 2}
]
result = novaclient.v1_1.shell._get_first_endpoint(endpoints, "ORD")
result = novaclient.v2.shell._get_first_endpoint(endpoints, "ORD")
self.assertEqual(endpoints[1], result)
def test_multiple_endpoints_but_none_suitable(self):
@ -2423,11 +2445,11 @@ class GetFirstEndpointTest(utils.TestCase):
{"region": "STU"}
]
self.assertRaises(LookupError,
novaclient.v1_1.shell._get_first_endpoint,
novaclient.v2.shell._get_first_endpoint,
endpoints, "ORD")
def test_no_endpoints(self):
"""If there are no endpoints available, an exception is raised."""
self.assertRaises(LookupError,
novaclient.v1_1.shell._get_first_endpoint,
novaclient.v2.shell._get_first_endpoint,
[], "ORD")

4
novaclient/tests/unit/v1_1/test_usage.py → novaclient/tests/unit/v2/test_usage.py

@ -14,8 +14,8 @@
import datetime
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1 import usage
from novaclient.tests.unit.v2 import fakes
from novaclient.v2 import usage
class UsageTest(utils.TestCase):

4
novaclient/tests/unit/v1_1/test_volumes.py → novaclient/tests/unit/v2/test_volumes.py

@ -14,8 +14,8 @@
# under the License.
from novaclient.tests.unit import utils
from novaclient.tests.unit.v1_1 import fakes
from novaclient.v1_1 import volumes
from novaclient.tests.unit.v2 import fakes
from novaclient.v2 import volumes
cs = fakes.FakeClient()

0
novaclient/tests/unit/v1_1/testfile.txt → novaclient/tests/unit/v2/testfile.txt

0
novaclient/tests/unit/v1_1/utils.py → novaclient/tests/unit/v2/utils.py

30
novaclient/v1_1/__init__.py

@ -1,4 +1,3 @@
# Copyright (c) 2012 OpenStack Foundation
#
# All Rights Reserved.
#
@ -14,4 +13,31 @@
# License for the specific language governing permissions and limitations
# under the License.
from novaclient.v1_1.client import Client # noqa
# NOTE(akurilin): This module is left for backward compatibility. Feel free to
# remove it, when openstack project will use correct way to
# obtain novaclient object.
# Known problems:
# * python-openstackclient -
# https://bugs.launchpad.net/python-openstackclient/+bug/1418024
# * neutron - https://bugs.launchpad.net/neutron/+bug/1418017
import sys
import warnings
from novaclient import v2
warnings.warn("Module novaclient.v1_1 is deprecated (taken as a basis for "
"novaclient.v2). "
"The preferable way to get client class or object you can find "
"in novaclient.client module.")
class MovedModule(object):
def __init__(self, new_module):
self.new_module = new_module
def __getattr__(self, attr):
return getattr(self.new_module, attr)
sys.modules["novaclient.v1_1"] = MovedModule(v2)

16
novaclient/v2/__init__.py

@ -0,0 +1,16 @@
#
# All Rights Reserved.
#
# 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
#
# 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.
from novaclient.v2.client import Client # noqa

0
novaclient/v1_1/agents.py → novaclient/v2/agents.py

0
novaclient/v1_1/aggregates.py → novaclient/v2/aggregates.py

0
novaclient/v1_1/availability_zones.py → novaclient/v2/availability_zones.py

0
novaclient/v1_1/certs.py → novaclient/v2/certs.py

66
novaclient/v1_1/client.py → novaclient/v2/client.py

@ -14,39 +14,39 @@
# under the License.
from novaclient import client
from novaclient.v1_1 import agents
from novaclient.v1_1 import aggregates
from novaclient.v1_1 import availability_zones
from novaclient.v1_1 import certs
from novaclient.v1_1 import cloudpipe
from novaclient.v1_1 import fixed_ips
from novaclient.v1_1 import flavor_access
from novaclient.v1_1 import flavors
from novaclient.v1_1 import floating_ip_dns
from novaclient.v1_1 import floating_ip_pools
from novaclient.v1_1 import floating_ips
from novaclient.v1_1 import floating_ips_bulk
from novaclient.v1_1 import fping
from novaclient.v1_1 import hosts
from novaclient.v1_1 import hypervisors
from novaclient.v1_1 import images
from novaclient.v1_1 import keypairs
from novaclient.v1_1 import limits
from novaclient.v1_1 import networks
from novaclient.v1_1 import quota_classes
from novaclient.v1_1 import quotas
from novaclient.v1_1 import security_group_default_rules
from novaclient.v1_1 import security_group_rules
from novaclient.v1_1 import security_groups
from novaclient.v1_1 import server_groups
from novaclient.v1_1 import servers
from novaclient.v1_1 import services
from novaclient.v1_1 import usage
from novaclient.v1_1 import versions
from novaclient.v1_1 import virtual_interfaces
from novaclient.v1_1 import volume_snapshots
from novaclient.v1_1 import volume_types
from novaclient.v1_1 import volumes
from novaclient.v2 import agents
from novaclient.v2 import aggregates
from novaclient.v2 import availability_zones
from novaclient.v2 import certs
from novaclient.v2 import cloudpipe
from novaclient.v2 import fixed_ips
from novaclient.v2 import flavor_access
from novaclient.v2 import flavors
from novaclient.v2 import floating_ip_dns
from novaclient.v2 import floating_ip_pools
from novaclient.v2 import floating_ips
from novaclient.v2 import floating_ips_bulk
from novaclient.v2 import fping
from novaclient.v2 import hosts
from novaclient.v2 import hypervisors
from novaclient.v2 import images
from novaclient.v2 import keypairs
from novaclient.v2 import limits
from novaclient.v2 import networks
from novaclient.v2 import quota_classes
from novaclient.v2 import quotas
from novaclient.v2 import security_group_default_rules
from novaclient.v2 import security_group_rules
from novaclient.v2 import security_groups
from novaclient.v2 import server_groups
from novaclient.v2 import servers
from novaclient.v2 import services
from novaclient.v2 import usage
from novaclient.v2 import versions
from novaclient.v2 import virtual_interfaces
from novaclient.v2 import volume_snapshots
from novaclient.v2 import volume_types
from novaclient.v2 import volumes
class Client(object):

0
novaclient/v1_1/cloudpipe.py → novaclient/v2/cloudpipe.py

0
novaclient/v1_1/contrib/__init__.py → novaclient/v2/contrib/__init__.py

0
novaclient/v1_1/contrib/assisted_volume_snapshots.py → novaclient/v2/contrib/assisted_volume_snapshots.py

0
novaclient/v1_1/contrib/baremetal.py → novaclient/v2/contrib/baremetal.py

0
novaclient/v1_1/contrib/cells.py → novaclient/v2/contrib/cells.py

0
novaclient/v1_1/contrib/deferred_delete.py → novaclient/v2/contrib/deferred_delete.py

0
novaclient/v1_1/contrib/host_evacuate.py → novaclient/v2/contrib/host_evacuate.py

0
novaclient/v1_1/contrib/host_evacuate_live.py → novaclient/v2/contrib/host_evacuate_live.py

0
novaclient/v1_1/contrib/host_servers_migrate.py → novaclient/v2/contrib/host_servers_migrate.py

0
novaclient/v1_1/contrib/instance_action.py → novaclient/v2/contrib/instance_action.py

0
novaclient/v1_1/contrib/list_extensions.py → novaclient/v2/contrib/list_extensions.py

2
novaclient/v1_1/contrib/metadata_extensions.py → novaclient/v2/contrib/metadata_extensions.py

@ -15,7 +15,7 @@
from novaclient.i18n import _
from novaclient.openstack.common import cliutils
from novaclient.v1_1 import shell
from novaclient.v2 import shell
@cliutils.arg(

0
novaclient/v1_1/contrib/migrations.py → novaclient/v2/contrib/migrations.py

0
novaclient/v1_1/contrib/server_external_events.py → novaclient/v2/contrib/server_external_events.py

0
novaclient/v1_1/contrib/tenant_networks.py → novaclient/v2/contrib/tenant_networks.py

0
novaclient/v1_1/fixed_ips.py → novaclient/v2/fixed_ips.py

0
novaclient/v1_1/flavor_access.py → novaclient/v2/flavor_access.py

0
novaclient/v1_1/flavors.py → novaclient/v2/flavors.py

0
novaclient/v1_1/floating_ip_dns.py → novaclient/v2/floating_ip_dns.py

0
novaclient/v1_1/floating_ip_pools.py → novaclient/v2/floating_ip_pools.py

0
novaclient/v1_1/floating_ips.py → novaclient/v2/floating_ips.py

0
novaclient/v1_1/floating_ips_bulk.py → novaclient/v2/floating_ips_bulk.py

0
novaclient/v1_1/fping.py → novaclient/v2/fping.py

0
novaclient/v1_1/hosts.py → novaclient/v2/hosts.py

0
novaclient/v1_1/hypervisors.py → novaclient/v2/hypervisors.py

0
novaclient/v1_1/images.py → novaclient/v2/images.py

0
novaclient/v1_1/keypairs.py → novaclient/v2/keypairs.py

0
novaclient/v1_1/limits.py → novaclient/v2/limits.py

0
novaclient/v1_1/networks.py → novaclient/v2/networks.py

0
novaclient/v1_1/quota_classes.py → novaclient/v2/quota_classes.py

0
novaclient/v1_1/quotas.py → novaclient/v2/quotas.py

0
novaclient/v1_1/security_group_default_rules.py → novaclient/v2/security_group_default_rules.py

0
novaclient/v1_1/security_group_rules.py → novaclient/v2/security_group_rules.py

0
novaclient/v1_1/security_groups.py → novaclient/v2/security_groups.py

0
novaclient/v1_1/server_groups.py → novaclient/v2/server_groups.py

2
novaclient/v1_1/servers.py → novaclient/v2/servers.py

@ -28,7 +28,7 @@ from six.moves.urllib import parse
from novaclient import base
from novaclient import crypto
from novaclient.i18n import _
from novaclient.v1_1 import security_groups
from novaclient.v2 import security_groups
REBOOT_SOFT, REBOOT_HARD = 'SOFT', 'HARD'

0
novaclient/v1_1/services.py → novaclient/v2/services.py

Some files were not shown because too many files changed in this diff

Loading…
Cancel
Save