Change v3 hosts to v2.1

This patch changes v3 hosts API to v2.1 and makes v2
unit tests share between v2 and v2.1.

The differences between v2 and v3 are described on the wiki page
https://wiki.openstack.org/wiki/NovaAPIv2tov3.

Partially implements blueprint v2-on-v3-api

Change-Id: I8ce66570edb06bde0bdea677e6e784539aaab763
Explicitly handle exception ConsoleTypeUnavailable for v2 consoles

In v3 remote_console extension, the exception ConsoleTypeUnavailable
is catched by explicitly. This patch changes the v2 api as same way,
and backport v3 unittest into v2 api.

Change-Id: I14f74e4a4b4ee84713b48cfc00d3f132726f9316
Handle non dict metadata in server metadata V2 API

While creating or updating the server metadata, requested metadata
should be in form of dictionary.
Currently if it is not in that form then, 500 error is being return
which should be 400.

This patch adds such request check for V2 API and adds its UT

Change-Id: Ifcd4f9d352de7b2676beff319b641547b8952566
Merge "Explicitly handle exception ConsoleTypeUnavailable for v2 consoles"
Use common get_instance function in v2 consoles extension

This patch use common get_instance function in v2 consoles extension.
That can make the instance behavior consistent with v2.1 api. Then
v2.1 and v2 can share same unittest.

Change-Id: Idf501be21178c3c97b1693e48d3fd13b97525299
Changes V3 remote_console extension into v2.1

This patch changes v3 remote_console API to v2.1 and makes v2
unit tests share between v2 and v2.1.
The differences between v2 and v3 are described on the wiki page
https://wiki.openstack.org/wiki/NovaAPIv2tov3.

Partially implements blueprint v2-on-v3-api

Change-Id: I5f15ec39d7201b2da3d7afbf1d0774e64e68c8fe
Merge "Handle non dict metadata in server metadata V2 API"
Merge "Change v3 hosts to v2.1"
Merge "Use common get_instance function in v2 consoles extension"
Merge "Changes V3 remote_console extension into v2.1"