vmwareapi: simple refactor of config drive tests

A fairly trivial refactor of multiple identical spawn
invocation calls.

Change-Id: I110df1786b4081abe72428f888c3d27430017ff1
remove 2 unused function in test_volumes.py

2 fake functions are not used in this test file, remove them

Change-Id: I35d374cb2cbffc0ba6d2ac761b4f7fd20b47401f
Update docstring for baremetal opportunistic tests

The db.test_migrations can test the migrations for Nova and nova
bare-metal. This patch updates the docstring on how to run those
tests opportunistically.

Change-Id: I327d688ec9af7dc0e8e0e58804bac8a3091cb727
Fixes evacuate doesn't honor enable password conf for v3

The evacuate api should honor enable_instance_password conf
setting just like server creation, rebuild and rescue api does,
enables this flag will returning the instance password from
server API call evacuate, If the hypervisor does not support
password injection then the password returned will not be
correct, this patch just fixes v3 evacuate api, since change
return value of v2 could potentially break apps which depend
on this being returned.

This patch also changes the evacuate response code to 202 to
keep consistency with api.

DocImpact
Change-Id: I2b9e5a067323ca84e2040e175a0425de3c0fafba
Closes-Bug: #1244203
Support IPv6 when booting instances

When nova uses neutron, IPv6 addresses may be allocated.  This ensures
those addresses are supported.

Change-Id: Ic904f3a7811b07264128bc62067cdf0bca9efac9
Closes-bug: #1267685
Make compute use quota object existing function

There are several places which check the admin project_id and
user_id with instance project_id and user_id in compute.
There is already a helper function in quota objects, make the code
use the existing one.

Change-Id: I73e7e53ad15eda3788607a1be09c27215d09bda1
vmwareapi:Fix nova compute service down issue when injecting pure IPv6

Use vmware center driver to static inject pure IPv6 address, since
IPv6 injection function still not be implemented, but it should not
throw exception, it will impact nova compute service work

Change-Id: I8d0835623202d48466a97798312b67f049ffb6c8
Closes-Bug: #1286006
VMware: add in debug information for network selection

Add in some debug information to assist remote debugging of networking
issues.

Change-Id: I3cdeb56e0745d4a964e6c6069325fadee99c1088
VMware: iscsi target discovery fails while attaching volumes

VMware Drivers are unable to discover iscsi targets because
the api calls fail to specify the iscsi server location
(referred in the code as target portal) to retrieve targets.
This is critical for the attach_volume feature to work with
iscsi supported cinder drivers.

Closes-Bug: #1235112

Change-Id: I60c06ae651bb2eb6d466a5ca61a09f289c21d1a3
Accurate comment in compute layer

Currently instance usually refer to an object instead of a dict
but comments didn't update in compute, this patch update it.

Change-Id: I7902f09b21c951c1e7a9d32a75b3c75208fb6d86
Add doc update for 4 filters which is missing in filter_scheduler.rst

DiskFilter
NumInstancesFilter
IoOpsFilter
PciPassthroughFilter
are missing in doc/source/devref/filter_scheduler.rst, add them.

DocImpact

Change-Id: I50868598c9769783e1677c9ec50abf031896af82
Closes-Bug: #1276575
VMware: Add a test helper to mock the suds client

Change-Id: I326abd0ee5a4b1512c34a63de5fea6a7ba1b6f77
Fix invalid vim call in vim_util.get_dynamic_properties()

Code was calling
vim.CancelRetrievePropertiesEx(token=obj_content.token)

This will be translated into a call to
vim_request_handler(managed_object, **kwargs) by Vim.__getattr__(),
which requires a managed_object argument.

This change also adds a test for vim_util.get_dynamic_properties which
exercises both property retrieval, and the cancellation of an
unfinished RetrieveResult.

Change-Id: Ie0d98cbded4dee680593d2a950510de25ee5fab7
Fixes NoneType vcpu list returned by Libvirt driver

* libvirt dom.vcpu may return a NoneType if vcpus dont exist

Change-Id: Iee10c2559ceea636bc4896595962e3470228ad35
Closes-Bug: #1274758
Remove mention of removed dhcp_options_enabled

Commit 3292103d80676fc789615465759de966dba4e9f7 removed
dhcp_options_enabled, remove it from the help string as well.

Change-Id: I1f89e0b809c5a47b02a11f2c013a8cbb6d0afa4a
Closes-Bug: #1289993
Fix typo and add test for refresh_instance_security_rules

Change Ia36b0dfb adds virt driver API method
refresh_instance_security_rules but there is a typo in the method's
docstring and it needs to be covered in test_virt_drivers.py.

Closes-Bug: #1290036

Change-Id: Idacffe2087f0bec6290e3422d1e777376b489615
Don't allow reboot when instance in rebooting_hard

It shouldn't allow reboot a instance while the instance in
rebooting_hard task state.
If the instance is in rebooting_hard, solf reboot action is
meaningless.

Change-Id: I43147104a7473eaaf1b86f84386bb28b7e3574c3
Closes-bug: #1288926
Instance groups: only display valid instances for policy members

When displaying the members we will validate that the members
are actually valid. There may be cases when the members of an instance
group are not all valid, for example the instance has been deleted.

This is part of blueprint instance-group-api-extension.

Change-Id: I77062ce14d337662254ca3be956620dda3f44cd7
Do not add HPET timer config to non x86 targets

HPET is a harware timer for x86 arch. Also, qemu option '-no-hpet'
is not supported on non x86 targets. This change does not add hpet
in the guest's timer config when the arch is not x86_64 or i686.

Closes-Bug: #1290362

Change-Id: I1b81d1c5ed4f900ed87d1ecbbb97d4fdb22405fa
Catch FloatingIpNotFoundForHost exception

When showing floating ips for a given host, the FloatingIpNotFoundForHost
exception isn't handled when no floating ips can be found for the host.
This patch fixes this bug.

Closes-Bug: #1289164
Change-Id: Ic25ffd66945fd40ba10d69515e0cbfeae840313c