High level interface using the connection classes to access the
various services. Only identity projects and list_flavors in
compute are implemented:
projects = conn.identity.list_projects()
The service filter has a valid_versions added to it to map the
module name to the version component of the endpoint URL. For
example, the v2.0 endpoint path is supported by the v2 SDK
network module:
https://region-a.geo-1.network.hpcloudsvc.com/v2.0/
is supported by the SDK module openstack.network.v2.
Implements: blueprint highlevel-interface
Change-Id: Ie52986a9da84c8f3395757c08de7a01be30e0f2a
I like the idea of having the examples in the code. I don't necessarily
like having to scroll through all those comments to get to the code. This
also changes the order of the documentation to summary, example, reference
versus summary, reference, example. I think I'm okay with that because
:class links will anchor to the reference section. Normally, seeing a
simple example first can be more useful.
This is a response to Doug's comment:
https://review.openstack.org/#/c/129937/1/doc/source/user_preference.rst
Change-Id: Ibbda909d2183edc6baeeec0bc56f01779334aabd
If py26 tests are run first, there is some incompatibility in the
.testrepository that breaks several tests. To get around this, you
need to run the py33 tests first. This change was made over in the
cliff project.
Before:
(.venv)terry@brat:~/hp/sdk$ rm -rf .testrepository/
(.venv)terry@brat:~/hp/sdk$ tox
...
py26: commands succeeded
py27: commands succeeded
ERROR: py33: commands failed
ERROR: py34: commands failed
ERROR: pypy: commands failed
pep8: commands succeeded
After:
(.venv)terry@brat:~/hp/sdk$ rm -rf .testrepository/
(.venv)terry@brat:~/hp/sdk$ tox
...
py33: commands succeeded
py34: commands succeeded
py26: commands succeeded
py27: commands succeeded
pypy: commands succeeded
pep8: commands succeeded
congratulations :)
(.venv)terry@brat:~/hp/sdk$
Change-Id: I64925097ce003659c4daa0e105bd06dc30726921
Add ability to extract a list of know versions from the service
catalog. Currently at least, the service catalog contains versions.
The get_versions method returns either a list of versions or an
[] empty list if the service catalog doesn't contain a detectable
version. If the service catalog does not contain a service, None
is returned.
Change-Id: I207553ca4bdd0083aff1802182039dde6ab72148
A service may have one default visibility, but the user should
be allowed to override that. For example listing tenants is
an administrative function by default, but is also available
over the public interface. This will work:
python examples/list.py openstack/identity/v2/tenant.py --os-api-visibility public
Change-Id: I4e40e55f9f7c369a9c3e900712a89fdbc743ffcb
Add a user preference class to collect user service preferences.
Sorry for all the test changes. I wanted to make the v2 and v3
tests have the same service catalog in a different format so that
the normalize catalog would be the same for both.
Closes-Bug: #1353030
Change-Id: Ice4e606255533425be7559916f083b4171566502
The v3 plugin handles an empty token value, but the v2 plugin
would attempt to authenticate with a token of ''. This change
should fix that.
Change-Id: Ia86377e7450a972bcb50303afeefacd9dc6426a9
Coerces string values to a boolean only when the prop is given a
type=BoolStr. BoolStr only accepts string words, no shortened values,
synonyms or integer values. When no acceptable value is found a
TypeError or ValueError is raised. Setters and Constructor calls
validate the attribute value as a fail-fast behavior.
Change-Id: I382426325522227a83ec5234c5116da97e71cfa2
Closes-Bug: #1365724
The connection class can be made with a transport and/or authenticator
that was already constructed or it can be made with nothing. The
create method will create a transport, authenticator and session if
they are needed. The normal use case would look something like:
conn = connection.Connection(**auth_args)
Change-Id: I27573bce799d9992748967b5ea1b575139a75853