cinder hardcodes the service type to "volumev2"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
ansible |
New
|
Undecided
|
Unassigned | ||
python-cinderclient |
Invalid
|
Undecided
|
Unassigned | ||
python-openstackclient |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
devstack creates a "volumev2" service-type for cinder with v2 endpoints in keystone's catalog. That is not the way that the catalog is designed to be used. The service-type should not be version-specific, and in fact devstack gets this right for every other service except cinder. But that's ok, because in non-devstack cases you setup the catalog yourself and can do so properly, calling the service-type "volume" as it should be. Unfortunately, when you do this, openstackclient's CLI does not work... it assumes the type must be volumev2 when you specify OS_VOLUME_
publicURL endpoint for volumev2 service in RegionOne region not found
Traceback (most recent call last):
File "/usr/lib/
result = cmd.run(
File "/usr/lib/
return super(Command, self).run(
File "/usr/lib/
column_names, data = self.take_
File "/usr/lib/
data = volume_
File "/usr/lib/
return self._list(url, resource_type, limit=limit)
File "/usr/lib/
resp, body = self.api.
File "/usr/lib/
return self._cs_
File "/usr/lib/
return self.request(url, method, **kwargs)
File "/usr/lib/
**kwargs)
File "/usr/lib/
resp = super(LegacyJso
File "/usr/lib/
return self.session.
File "/usr/lib/
resp = super(TimingSes
File "/usr/lib/
return func(*args, **kwargs)
File "/usr/lib/
**endpoint_
File "/usr/lib/
return auth.get_
File "/usr/lib/
service_
File "/usr/lib/
return func(*args, **kwargs)
File "/usr/lib/
raise exceptions.
EndpointNotFound: publicURL endpoint for volumev2 service in RegionOne region not found
clean_up ListVolume: publicURL endpoint for volumev2 service in RegionOne region not found
Traceback (most recent call last):
File "/usr/lib/
ret_val = super(OpenStack
File "/usr/lib/
result = self.run_
File "/usr/lib/
ret_value = super(OpenStack
File "/usr/lib/
result = cmd.run(
File "/usr/lib/
return super(Command, self).run(
File "/usr/lib/
column_names, data = self.take_
File "/usr/lib/
data = volume_
File "/usr/lib/
return self._list(url, resource_type, limit=limit)
File "/usr/lib/
resp, body = self.api.
File "/usr/lib/
return self._cs_
File "/usr/lib/
return self.request(url, method, **kwargs)
File "/usr/lib/
**kwargs)
File "/usr/lib/
resp = super(LegacyJso
File "/usr/lib/
return self.session.
File "/usr/lib/
resp = super(TimingSes
File "/usr/lib/
return func(*args, **kwargs)
File "/usr/lib/
**endpoint_
File "/usr/lib/
return auth.get_
File "/usr/lib/
service_
File "/usr/lib/
return func(*args, **kwargs)
File "/usr/lib/
raise exceptions.
EndpointNotFound: publicURL endpoint for volumev2 service in RegionOne region not found
Catalog is as follows in this case:
[root@ip9-
+------
| Name | Type | Endpoints |
+------
| cinder | volume | RegionOne |
| | | internal: http://
| | | RegionOne |
| | | admin: https:/
| | | RegionOne |
| | | public: https:/
| | | |
The cinderclient CLI has the same problem. It at least provides a workaround in that you can specify "--service-type volume", though that is really a hack. Surely the code could look for "volumev2" (for those deployments that have followed devstack's bad example) and then failing to find that look for "volume" (for those that have done things correctly).
From an OSC perspective, this is a frustrating change to make. The catalog should not contained versioned types (volume, volumev2, volumev3); and ideally, the URLs specified should be versionless.
We could make use of the "service_type" arg available in the v2 client, but I'm not sure how we would pick up on this. As seen in your example, the error happened now upon client instantiation, but upon accessing an API.