From 82c5f9b23907fbef9b4566355fba032e53d8366f Mon Sep 17 00:00:00 2001 From: Sean McGinnis Date: Wed, 14 Nov 2018 05:22:54 -0600 Subject: [PATCH] Remove v1 check in Cinder client version lookup The Cinder v1 API was deprecated in Juno on removed completely in Queens. We no do not support compatibility between Stein Nova and Queens Cinder, so this checking can be removed. Change-Id: I947f50e921159f66b425f10e31a08a3e0840228e Signed-off-by: Sean McGinnis --- nova/volume/cinder.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/nova/volume/cinder.py b/nova/volume/cinder.py index 90e27fee0a83..37b308b328d1 100644 --- a/nova/volume/cinder.py +++ b/nova/volume/cinder.py @@ -126,11 +126,11 @@ def _get_server_version(context, url): # NOTE(andreykurilin): endpoint URL has at least 2 formats: # 1. The classic (legacy) endpoint: - # http://{host}:{optional_port}/v{1 or 2 or 3}/{project-id} - # http://{host}:{optional_port}/v{1 or 2 or 3} + # http://{host}:{optional_port}/v{2 or 3}/{project-id} + # http://{host}:{optional_port}/v{2 or 3} # 3. Under wsgi: - # http://{host}:{optional_port}/volume/v{1 or 2 or 3} - for ver in ['v1', 'v2', 'v3']: + # http://{host}:{optional_port}/volume/v{2 or 3} + for ver in ['v2', 'v3']: if u.path.endswith(ver) or "/{0}/".format(ver) in u.path: path = u.path[:u.path.rfind(ver)] version_url = '%s://%s%s' % (u.scheme, u.netloc, path)