Enhance V3 router class for resources

RESTful APIs are resource-oriented, and Keystone provides a
RESTful API, but the current way that routes are being mapped is
based on URLs rather than resources. With this change, the base
Routers class is enhanced to support a resource-oriented way to
map paths to controllers and methods.

bp json-home

Change-Id: I0ba856845116b3ddd3dfed4608be65a87d9c01dc
Remove assignment controller dependency on token_api

The assignment controller now uses the `validate_token` method on
the `token_provider_api` instead of referencing `get_token` directly
from the token persistence service.

The user_crud contrib (v2.0) extension now will emit an actual
token to the wire instead of the raw-internal data structure from
the token persistence backend. The intent here was clear by the
fact that the structure was built to look like a v2.0 token,
however, it was retriving the data from the persistence backend
and just updating the token_id then resaving the data before
emitting the raw persistence data (incorrect). The extension
now uses the issue_v2_token method from the token_provider_api.

This change is to ensure interactions with the token persitence
are consistent so that it is possible to support toggling
persistence of tokens.

Change-Id: I22b6b837731566bfd4dc61a47eec2eb0d336d4d1
bp: non-persistent-tokens
Expose token revocation list via token_provider_api

Use the token_provider_api for the token revocation list instead
of directly accessing the token persistence service.

Tests have been updated to compare results from the token_api
and the token_provider_api for the revoked token list.

This change is to ensure interactions with the token persitence
are consistent so that it is possible to support toggling
persistence of tokens.

Change-Id: Ic3982329dd28db5b2f974fadbab6c5e010365d27
bp: non-persistent-tokens
Remove ec2 contrib dependency on token_api

The ec2 contrib extension now utilizes the `validate_token` method
from the `token_provider_api` instead of directly referencing the
token persistence service.

This change is to ensure interactions with the token persistence
are consistent so that it is possible to support toggling
persistence of tokens.

Change-Id: Iad6c13d027fffdb23497f22b29a9ce6d5009f158
bp: non-persistent-tokens
add i18n to lxml error

This tweaks the error message to be a complete sentence, which should
make translation easier, and wraps the message in a gettext call.

Change-Id: Ic240d4bbc7f03df4b9c76e642be3779341519c1c
Clean whitespace off token.

A bogus, non-visible character may be appended to the token.
If it is, the hash will not match the original, and the token
will be incorrectly reported as invalid.

Change-Id: I7b2c831b85818a8c07616f44c1d501701c9d72f8
Closes-Bug: 1354765
Merge "Expose token revocation list via token_provider_api"
Merge "Remove ec2 contrib dependency on token_api"
Merge "Enhance V3 router class for resources"
Merge "Remove assignment controller dependency on token_api"
Merge "add i18n to lxml error"
Merge "Clean whitespace off token."