Remove new constraint from migration downgrade.

Remove the foreign key constraint for user_id. Whilst it is a foreign
key the constraint was not set in the previous schema. Also sets the
columns names to unicode as they were in previous schema.

Fixes: bug 1169381
Change-Id: I9b1ac5305622d68a7e124ba8100a4b8166b43af0
Delete extra dict in token controller.

Change-Id: Ieb88d50f378b46cb0e91a84142cbaf07c3f3defb
Signed-off-by: You Ji <jiyou09@gmail.com>
Make migration tests postgres & mysql friendly.

Add some session commits to prevent database deadlocks.
Force close all open sessions before performing tear down.
Use escaped parameter handling for raw sql statements.

Change-Id: I0ef670ddc416a02e78570ab6ebed2b4bf2a8635b
Merge "Remove new constraint from migration downgrade."
Merge "Make migration tests postgres & mysql friendly."
Merge "Delete extra dict in token controller."