Fix typo of ANS1 to ASN1

Replace is_ans1_token with is_asn1_token in test of v3 auth. This is dependent
upon the review of python-keystoneclient. https://review.openstack.org/87069

Change-Id: I5ab0205f9c58a769cd1f2a5ffe51ca37d981fe67
Closes-bug: 1306874
Added statement for ... if ... else

Statement for ... if ... else was insert where it possible.

Change-Id: Ic74d9c0a9e7de597c22f72f5cef3c01ea5fd87a0
Explicit foreign key indexes.

Overview:
MySQL requires indexes on foreign keys. Such an index is created on the
referencing table automatically if it does not exist.

Motivation:
MySQL names foreign keys indexes differently dependent from itself
version. Implicit fk indexes is MySQL specific behavior, so it should be
ignored during comparision. We plan to use Alembic to compare models and
migrations I0758c7e09d1d46ce870c3f94f76c2a177955e143. Alembic doesn't support
5.5 naming convention. So we need consistent index name for all MySQL versions
to be easily ignored.

Solution:
A new migration script renames incorrectly named fk indexes on MySQL.

Reproduction:
Stop execution when foregn keys will be initialized. See schema with
your MySQL shell client. With 5.5, indexes which was not named
explicitly, will have a name such as <tablename>_<columnname>_fk, with 5.1 it
will be <columnname>.

Change-Id: I01ba0c8856afbda59394395ac319bf83a55ee2be
Partial-Bug: #1292591
Compatible server default value in the models.

MySQL has no native boolean type. MySQL boolean type is just an alias
to tiny int type field. So MySQL returns '"1"' for `true` value and
'"0"' for false value. Instead of it, Postgres has native boolean type.
Thus with Postgres, reflection of a boolean type column default value will
return either 'true' or 'false'. Model must have compatible
`server_default` argument in columns definition.

Change-Id: Id0107d510dd7087e61ae851a1f3ff18334851a68
Partial-Bug: #1292591
Updated from global requirements

Change-Id: I7d0c63125bce2d59c23a2e8da63eb0b96b169258
Merge "Explicit foreign key indexes."
Merge "Compatible server default value in the models."
Merge "Updated from global requirements"
Merge "Fix typo of ANS1 to ASN1"
Merge "Added statement for ... if ... else"