Update instance.node on evacuate

The evacuate API works like a migration from a dead node. As part of
migration, the instance.node property is updated to reflect the target
node that the instance is migrating to. This is later used when the
migration is confirmed/reverted. The problem is when an instance is
being evacuated, the node property isn't getting updated and the
instance will have the old (dead) node value set on it after it's
evacuated. This patch updates instance.node when the instance is
evacuated.

Fixes bug 1198284

Change-Id: I4901fb937160e955df7c97c37265783e844fdbef
Add a VIF driver for IOVisor engine

Implements blueprint iovisor-vif-driver

Unit Test is included
Follows the same structure that OVS and Qbh drivers
Includes the rootwrap config to allow calls to ifc-ctl for managing IOVisor engine.

Change-Id: I346b4d84a6e48d56f307349ed681355d26710ecd
Port used limits extension to v3 API Part 1

This changeset only copies the v2 implementation file into the
appropriate v3 directory unchanged. The copy as-is will not be
loaded by either the v2 or v3 extension loaders. The second
changeset will then make the changes required for it to work as a
v3 extension.

This is being done in order to make reviewing of extension porting
easier as gerrit will display only what is actually changed for v3
rather than entirely new files.

Partially implements blueprint nova-v3-api

Change-Id: I34214370f53d481346eb11fec6b8fd0ddeb42918
Prompt error message when creating aggregate without aggregate name

When using API to create an availability zone via aggregate, the
prompt message will be "There was a conflict when trying to complete
your request" if the request body looks like below.
{"aggregate": {"name": "", "availability_zone": "zy1_zone53335"}}

The message is not accurate, aggregate name should not be null.

Fixes bug 1188032
Change-Id: I1fb74186886283a9b6763abb665b8ce42e4bb24c
Port used limits extension to v3 API Part 2

Ports the used limits extension and the corresponding unittests to
the v3 framework.

Partially implements blueprint nova-v3-api

Change-Id: I6f1aa507ffd297e56d9cfd23972bc3bb15ba181a
Fix blocking issue when powervm calculate checksum

In powervm driver, it takes long time to calculate file checksum
before and after transferring image file. Because nova-compute is
a single thread, it won't process any other work at the same time.
Here give other threads chance to run by using time.sleep(0), that
acts as a yield of the thread for eventlet.

Fixes bug #1181895

Change-Id: I79fbd9d7d4fb7791ca599b136cf9945dec8996e2
Make Instance object properly update *metadata

Currently, the Instance object won't notice when metadata or
system_metadata has changed and thus won't include it in updates it
makes to the database.

We could make these two dicts full-fledged objects, but that's a bit
overkill for this purpose. Stash a copy of them every time we reset
our changes so that we can detect changes in save().

Note that this includes tests to some shelve tests which are now
wrong because they modify the instance's sys_meta prematurely.
Turns out, these are the tests that pointed out the need for
this tracking :)

Related to blueprint unified-object-model
Fixes bug 1201776

Change-Id: I3df462645979742379a41060cda5bb5084fddb20
Fix Instance object handling of implied fields

The situation around info_cache and security_groups is a bit
confusing and inconsistent at the moment. Since some of the
"all" queries don't join info_cache and security_groups,
avoid assuming that they are there, either triggering an
unintentional lazy load, or a KeyError in a few cases where the
DB API returns a dict.

Also, don't ever allow us to recurse into another instance object
looking for a loaded attribute in case it fails to load from the
get query.

Related to blueprint unified-object-model

Change-Id: I40b72274cd24034b03c8e07af56e7c8d49b6b898
Fix shelve's use of system_metadata

The shelve patches needed to include a hack to make the changes
to system_metadata get saved properly. Now that it's fixed,
clean that up.

Related to blueprint unified-object-model

Change-Id: I79a2db66544e0662e48445505a818ff62f765569
Fix duplicate osapi_hide_server_address_states config option

This is causing an error in the config file tool generator.
Import the config option from the v3 API copy of this code.

Change-Id: I5a03f509c91de080d3753bf351d891d06600e84b
Fix accessing to '/' of metadata server without any checks to work

Accessing to '/' of metadata server to get version information should
be allowed without any checks. Due to the wrong comparison condition,
it failed.

Change-Id: Ia8603c321839b959b120af1d018f061f438155c7
Fixes: bug #1192774
Move resource usage sync functions to db backend

Resource usage sync functions was declared in nova/quota.py, and
using db.api public methods. This functions was moved to database
backend implementation, so now sync functions can use private
methods of database backend, and session attribute can be removed
from this public methods, and even some public methods can be removed.

Blueprint: db-session-cleanup

Change-Id: I63eeb18b8ede4b4263ee553d4e70633de463e0c4
Remove unnecessary comments for instance rebuild tests.

Just remove the unnecessary comments which may be confused.

Change-Id: I86df10a4ce1fc88e7dd47764e4ea0cdeababd389
Disable ssl layer compression for glance requests.

This may improve data throughput, eg when high network bandwidth is
available and you are using already compressed image formats such as
qcow2 .

Addresses bug 1189887.

Change-Id: Iacc42d8e0cab218258c3029d5395e02fddb75197
Merge "Add a VIF driver for IOVisor engine"
Merge "Move resource usage sync functions to db backend"
Merge "Fix blocking issue when powervm calculate checksum"
Merge "Fix accessing to '/' of metadata server without any checks to work"
Merge "Prompt error message when creating aggregate without aggregate name"
Remove duplicate cells_rpcapi test.

The same test was defined twice.  This removes the second instance of
it.

Change-Id: I91e083b412428f90f62c40eb8f47523b48830322