Hypervisor uptime fails if service is disabled

Getting the uptime of a hypervisor fails because the db query
used to get the service filters out disabled hosts.

Instead we replace that query with one that always gets the
service if it exists, and a check that the sevice is up to
avoid an rpc call to a non running service.

Fixes bug 1195052

Change-Id: I97bc8a5002bd0f333207403d5b1878649612b762
Fix compatibility with older confirm_resize() calls

Commit ff4194bec79067bf77ab25caec1e40ad3709ea07 bumped the RPC
version and format for compute_confirm_resize() without providing
compatibility with older installations. This patch converts it
to a instance-dict style of primitive before sending it, if we're
pinned to an older version.

Change-Id: Ic631b70c005bfd0efe6965ad024890cc2caf947c
Remove notify_on_any_change option

This option isn't really needed, since the case it defends is already
covered by notify_on_state_change. Let's simplify the configuration a
bit by removing it.

DocImpact

Change-Id: I35071abdea2d2380d79c07e9134e095bda65a13d
Signed-off-by: Julien Danjou <julien@danjou.info>
Remove references to deprecated DnsMasqFilter

In https://review.openstack.org/#/c/16803/ compatibility
for FLAGFILE has been added. It is time to remove this
again for Havana.

Change-Id: I1304132320f7d7d381b9e6548337afed52f1e96a
Sync harmless changes from oslo-incubator

Includes these commits:

  3948aee Highlighting the deprecated nature of 'log-format'.
  b21fc56 Fix bad default for show_deleted
  d28fa69 python3: Add python3 compatibility.
  0bf03b7 Add network_utils.urlsplit
  e456727 Remove useless logging in networks_utils
  7119e29 Enable hacking H404 test.
  b41862d Use param keyword for docstrings
  2f01388 Use Python 3.x compatible except construct
  e3545f8 Enable hacking H402 test
  484a1df Enable hacking H403 test
  35660da Enable hacking H401 test
  874249e Add support for requirements.txt.
  b135234 Remove the notifier and its dependencies from log.py
  926b3e9 Fixes import order nits

Changes which may look not look so harmless:

 - the common get_admin_context() method is not used by Nova
 - network_utils.urlsplit() is added but not used yet
 - suppport for requirements.txt is added to patch_tox_venv but
   actually it doesn't use those files

Change-Id: I03e67f4648dcaf57620f11e63cfd8e7dbe3665cb
Port admin-actions API into v3 part2

This patch contains the changes required to adapt the admin-actions
extension and the corresponding unittest to the v3 framework.

Partially implements bp v3-api-extension-versioning

Change-Id: Ib109f52999de8e986c258d8d9d35d8193e8b0851
Changes select_destinations to return dicts instead of objects

This patch refactors the select_destinations to return a dict
instead of a HostState object. As the result of this change, no
additional code needs to be added to jsonutils.to_primitive
function.

Partially implements bp cold-migrations-to-conductor

Change-Id: Ic24080766e48abff36bbbe2c04fa5da77621fde5
Port service API to v3 Part 2

This patch contains the changes required to adapt the service
extension and the corresponding unittest to the v3 framework

This also fix the xml/json inconsistance issue in update:
1:add root element 'service' for json format.
2:merge the extended_service.
3:raise HTTPBadRequest instead of HTTPUnprocessableEntity

Partially implements: bp v3-api-extension-versioning
Partially implements: bp v3-api-inconsistencies

Change-Id: I88cfbe69e0bc0351e81a831345f2a36bf63f5f4f
port AvailabilityZone 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: I88f81d76a8dd0559e5a64a3c9d8aa93c6d2fa107
Port AvailabilityZone API to v3 Part 2

This patch contains the changes required to adapt the AvailabilityZone
extension and the corresponding unittest to the v3 framework. Moves the
commented out tests from the v3 version of test_servers to the config
drive extension unittests.

Partially implements: bp v3-api-extension-versioning

Change-Id: I2cf214061e3accbb056ca53c224df1c5bf74a6e4
Handle ImageNotAuthorized exception

Handle ImageNotAuthorized exception if user have no access to update image metadata

Change-Id: I558cc2c31174f7f619061882bfdab6df35203254
Fixes: bug #1194768
Remove locals() from virt directory

fixes bug 1171936

Change-Id: Id91f2fd516f57970d3af59c1bae6e8da46c5482c
Imported Translations from Transifex

Change-Id: I3f39a3eb723e9d931e11caa4ef611f1c3646c2ae
port instance_actions 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: I7e59afc952f668c0d8933463c5d4a5843d36802f
Port instance_actions API to v3 Part 2

This patch contains the changes required to adapt the agent
extension and the corresponding unittest to the v3 framework

Partially implements: bp v3-api-extension-versioning

Change-Id: Ibf0784a455942185799d40395fab5e8eb112e2d8
Merge "Handle ImageNotAuthorized exception"
Merge "Remove locals() from virt directory"
Merge "Imported Translations from Transifex"
Merge "Port service API to v3 Part 2"
Merge "Port admin-actions API into v3 part2"