Sync v2/v3 console_output API extensions

Synchronises changes made to the v2 version of the console_output
API extension to v3 in commit c651f4928c65407cff86a9f9efc046a0f76a9519
which fixed bug  #1194032

Partially implements blueprint nova-v3-api

Change-Id: Ie28d771d25636decb7b1f17756654be56762b35f
port disk_config API into v3 part1

This changeset only copies the v2 files into the appropriate v3
directories 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 tried 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: bp v3-api-extension-versioning

Change-Id: Ia2ef4ab8cb63878d16360378c61e5182f4593200
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
Fix IPAddress and CIDR type decorators

Use load_dialect_impl() user hook instead of calling
with_variant() on a type implementation in IPAddress
and CIDR type decorators. This makes this code work
with SQLAlchemy 0.8.x versions.

Fixes bug 1200231

Change-Id: Ib0eb582f472116bda817d3e35e26888dc116ad58
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
Remove redundant if statements in cells.state

Removed redundant if statements since checking if cell is None twice
was not intuitive.

Change-Id: I20d7ade5acd27d23ba53ef065d0e4d24218182c2
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
Remove unnecessary comments for instance rebuild tests.

Just remove the unnecessary comments which may be confused.

Change-Id: I86df10a4ce1fc88e7dd47764e4ea0cdeababd389
Refresh network cache when reassigning a floating IP in Neutron

When Nova associates or disassociates a floating IP address
the network info cache is always refreshed due to the
@refresh_cache decorator

However if you (re)associate a floating IP which is already
associated with another instance on a Neutron based system then
the address is correcly disassociated first, but the cache refresh
is not trigged for the original  instance. As a result Nova will
show the same address for two instances until the periodic
clean-up kicks in some minutes later.

Fixed bug: 1173227

Change-Id: Iea81532911478026b9b2c0578a1eda7a97b09d80
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
Create key manager interface

This interface provides a thin wrapper around an underlying key management
implementation such as Barbican or a KMIP server. The key manager interface is
used by the volume encryption code to retrieve keys for volumes.

Implements: blueprint encrypt-cinder-volumes
Change-Id: I9b0dcb7d648ee6809185c71ba457c8a8a6c90d50
SecurityImpact
Merge "Fix duplicate osapi_hide_server_address_states config option"
Merge "Port used limits extension to v3 API Part 1"
Merge "Port used limits extension to v3 API Part 2"
xenapi: no glance upload retry on 401 error

It is possible for a token to expire during a very long image upload.
If this happens, there is little point in retrying the upload, as it
is most likely to fail again for the same reason.

Fixes bug 1199454

Change-Id: Id699135a8ec4c603671b16f0127d0b2cd2a55855
Fix HTTP response for PortInUse during boot

If an in use port is passed as a network parameter in the request, Nova API
should raise an HTTPConflict (409) error

Fixes bug #1160887

Change-Id: I60103610f9143f1c668927fe40d10a14b39b4c25
Merge "Create key manager interface"
Merge "Remove unnecessary comments for instance rebuild tests."
Merge "xenapi: no glance upload retry on 401 error"
Merge "Disable ssl layer compression for glance requests."