Fix documentation example again

In d0617885 the example in the Service Discovery section was changed to
include the full URL of the endpoint. On closer inspection, it turns
out that the example is deliberately pointing out that you don't need
the full URL when using endpoint filtering, since the endpoint filter
is supposed to look up the endpoint in the catalog. The reason it
wasn't working out of the box, as pointed out in the bug[1], was that
devstack sets up v2.0 endpoints, so the example path was appending /v3
to a v2.0 endpoint and failing.

This patch reverts the example back to using just a path, but omits the
'/v3' part of the path and uses the admin interface so that it will
work on v2.0. This will work out of the box on devstack and will still
work if the user has set up endpoints with '/v3' in them.

[1] https://bugs.launchpad.net/keystoneauth/+bug/1519054/comments/2

Change-Id: I11637aaa1939327eb6d1819c1b740a99e0f21e83
This commit is contained in:
Colleen Murphy 2016-04-15 10:58:40 -07:00
parent d1205b24bd
commit 7d0cb04e6d

View File

@ -135,9 +135,9 @@ contains all the information an authentication plugin requires to determine the
correct URL to which to send a request. When using this mode only the path for correct URL to which to send a request. When using this mode only the path for
the request needs to be specified:: the request needs to be specified::
>>> resp = session.get('https://my.keystone.com:5000/v3/users', >>> resp = session.get('/users',
endpoint_filter={'service_type': 'identity', endpoint_filter={'service_type': 'identity',
'interface': 'public', 'interface': 'admin',
'region_name': 'myregion'}) 'region_name': 'myregion'})
`endpoint_filter` accepts a number of arguments with which it can determine an `endpoint_filter` accepts a number of arguments with which it can determine an