summaryrefslogtreecommitdiff
path: root/keystoneclient/_discover.py
diff options
context:
space:
mode:
authorJamie Lennox <jamielennox@redhat.com>2014-02-19 15:35:46 +1000
committerJamie Lennox <jamielennox@redhat.com>2014-06-23 07:19:52 +1000
commit11336acf8868a2709cb583af9bbd8a1c442d137f (patch)
tree6c01741fb976f2ff961bcbfe30d04989a7f52cf2 /keystoneclient/_discover.py
parent6c47b937c3c39f0fcb9dbfb7025d92b063671610 (diff)
downloadpython-keystoneclient-11336acf8868a2709cb583af9bbd8a1c442d137f.tar.gz
Unversioned endpoints in service catalog
If you pass a version number to the endpoint_filter then an identity plugin will make a request to the URL in the service catalog and find an appropriate URL for the requested version. It caches the response to each of the discovery queries so that it should only query once per URL. This will only work for applications that create session objects directly as the legacy model does not use the get_endpoint features of an identity plugin. This change showed an inconsistency in the docstrings between discovery and the usage of discovery so the docstring was fixed. Blueprint: endpoint-version-query Change-Id: I277f2f6ad6c8cd44f1a9c06cf07d62bc8f8b383b
Diffstat (limited to 'keystoneclient/_discover.py')
-rw-r--r--keystoneclient/_discover.py12
1 files changed, 10 insertions, 2 deletions
diff --git a/keystoneclient/_discover.py b/keystoneclient/_discover.py
index 4891f27..5f50027 100644
--- a/keystoneclient/_discover.py
+++ b/keystoneclient/_discover.py
@@ -228,7 +228,11 @@ class Discover(object):
return versions
def data_for(self, version, **kwargs):
- """Return endpoint data for a specific version.
+ """Return endpoint data for a version.
+
+ :param tuple version: The version is always a minimum version in the
+ same major release as there should be no compatibility issues with
+ using a version newer than the one asked for.
:returns dict: the endpoint data for a URL that matches the required
version (the format is described in version_data)
@@ -244,7 +248,11 @@ class Discover(object):
return None
def url_for(self, version, **kwargs):
- """Get the endpoint url for a required version.
+ """Get the endpoint url for a version.
+
+ :param tuple version: The version is always a minimum version in the
+ same major release as there should be no compatibility issues with
+ using a version newer than the one asked for.
:returns str: The url for the specified version or None if no match.
"""