Shrink devref.unit_tests, since info is in wiki.

Don't keep a copy of the run_tests.sh flag list here since it
inevitably will get out of sync with the real list.

No need to go into detail on how unit testing is set up, since we already have a wiki
on how to run tests that applies for all OpenStack projects. Keep
section with tox examples since that is the most commonly used command.

Change-Id: Ia8eb059be164d9df3edfd69aedcebfd028da45ff
Related-Bug: 1219040
VMware: remove unused parameters in imagecache

Trivial patch to remove some unused parameters in
timestamp_cleanup().

Change-Id: Id3c6e8c6c504591fdf09e8871cf3358d265a678c
Fix api direct use of instance module objects

This switches the nova/api and nova/tests/api code to use
nova.objects.Instance* vs nova.objects.instance.Instance*.

Partial-Blueprint: object-subclassing

Change-Id: I146f1d082fa37e1a5c09aa8c5363746daffbc219
libvirt: convert cpu features attribute from list to a set

Currently, the cpu features list which is being sent to libvirt,
when creating a domain or calling compareCPU, must contain only
unique entries. Multiple issues arise when we are updating the
features attribute in LibvirtConfigCPU class (for example during
migration).

This change will change the features attribute from being a list
to a set. This make the LibvirtConfigCPU class keep only unique
features.
Adjusting the LibvirtConfigCPUFeature class to support set
operations by overriding the __eq__, __ne__ and __hash__
methods.

Closes-Bug: #1303536
Change-Id: I6350fe0e827c860aea77cc4fe56f18f5c1483580
Add testing for hooks

Partially implements: bp instance-network-info-hook

Change-Id: Ie7cfcf70ff39f1273d97b17788c2e4e0f9fc437f
Make get_console_output() use objects

This changes the get_console_output() method in compute manager to take
objects.

Related to blueprint compute-manager-objects-juno

Change-Id: Ia8cb2168313903d5255fa2c9616ee2a56aebdb68
Add deprecation warning to nova baremetal virt driver

We have warnings in the other group C virt drivers and for cells, and
given the baremetal driver is deprecated and slated to be replaced by
the ironic driver, add a deprecation warning to the logs when the
baremetal driver is loaded.

Change-Id: Iaee8b7f7b4d32605e36fd72e893794066727fb65
Revert "Allow admin user to get all tenant's floating IPs"

This reverts commit 6478554f531f6ee2fa86226fbc79dd31e556bc06.

This API change merged as a bug fix and introduced bugs and our API
change policy is more or less to go through the blueprint/nova-specs
review process:

http://lists.openstack.org/pipermail/openstack-dev/2014-June/037536.html

So reverting this so it can go through the blueprint/nova-specs
review process.

There should be minimal impacts to removing this (broken) API since
it merged not too long ago and was added strictly for Ceilometer's
usage, not an external deployer that would be (more) broken by this
API removal.

Closes-Bug: #1328694

Change-Id: I22a711795ea616aabc155a71703c9c794e84a5dc
Save connection info in libvirt after volume connect

The libvirt driver will connect volumes for BFV while processing
the guest configuration, but not save the connection_info into
the database. This adds a save there to make sure that any
storage driver details get persisted.

Change-Id: Ia99e04ad80a2823a6852debf0919e72b2f93bd26
Related-bug: #1328245
Failure during termination should always leave state as error()

Currently we have a situation where if an instance fails to delete,
instead of having its state reverted, like we do in most places we set
it to error,deleting. This was intentionally done in
I5fb1bbd56035792f566a6e076edfe7a69df006ef. We also intentionally ignore
duplicate requests to delete an instance if its already being deleted
(I2f97f93bd714e0ea3b6d4fa3ac457ab43eed00e1). The combination of these two
things means that if an instance fails to delete for some reason a
tenant is unable to delete that instance.

It turns out this is really bad because instances in deleting state
count against quota, so the tenant slowly looses usable quota.

To fix this, upon a failed termination set the vm_state to error and
revert the task_state. This is a partial revert of
I55742203bdd071c7df90902868e46c2020f799bd.

Change-Id: I55742203bdd071c7df90902868e46c2020f799bd
Closes-Bug: #1329559
Skip migrations test_walk_versions instead of pass

When there is no db engine configured for the migration tests,
the test_walk_versions test was passing, rather than skipping,
because it contained a for-loop and no check for the length of the
sequence being iterated over.
This patch checks the length of the configured engines and
properly skips the test when there are no engines.

Change-Id: I4078655f01638c22cf029f088018b8be93d6a01a
Co-Authored-By: Devananda van der Veen<devananda.vdv@gmail.com>
Closes-bug: #1327397
Prevent clean-up of migrating instances on compute init

During compute manager startup init_host is called. One
of the functions this carries out is to delete instance
data that doesn't belong to this host this function only
checks if the local instance belongs to the host or not.
It doesn't check the task_state. This could result in the
loss of all instance data if it occured at the wrong
point during live migration.

This change checks if the task_state of the instance to
be deleted is MIGRATING and if so it does not delete the
instance. Similarily for the task state RESIZE_MIGRATING.

Change-Id: Ia8c67acf93d71af868907f0711dcc1dfe103560c
Closes-Bug: 1319797
Merge "Add deprecation warning to nova baremetal virt driver"
Add more logging to nova-network.

As requested to help debug gate issues.

Related-Bug: #1298472

Change-Id: I5640df721345fe9a878c7c6f8e1c13cfed484112
Merge "libvirt: convert cpu features attribute from list to a set"
Test force_config_drive as a boolean as last resort

The force_config_drive help clearly states that only possible option is
'always' but folks are setting it to 'True'/'False' etc and expecting
it to work. So let's enable that as well. In the worst case scenario
mentioned in the bug, it was set to 'False' and since the check for
force_config_drive took any string as true, we were enabling the flag
to true. With the change in this review, we force a conversion of the
string to true. Additional check for the flag to be set as 'always' is
treated as true as well. The test case checks for all the variations

Closes-Bug: #1319180
DocImpact

Change-Id: Ifa6348fa7dfd9de063eb13d30e3ddf94fa530b57
Merge "Fix api direct use of instance module objects"
Merge "Skip migrations test_walk_versions instead of pass"
Merge "Save connection info in libvirt after volume connect"
Merge "Failure during termination should always leave state as error()"