baremetal: Add missing method to volume driver

Added get_hypervisor_version(), which is called by underlying
LibvirtVolumeDrivers. Also added tests roughly checking if the
underlying drivers can be loaded and be called without error.

Partial-Bug: #1208707
Change-Id: Ida6b6800d1ef518c6e76d6b2ab4ac2f795a744ca
Add V3 API sample for admin-password

Adds api sample tests and api samples for admin-password

Partially implements blueprint v3-api-unittests

Change-Id: Iade39ff931471d1d68e358ac5d35a1921e85df66
Adding support for multiple hypervisor versions

This is to prevent instances with newer tools from being provisioned
on older hypervisors.
Added comparison of hypervisor version from the compute-node and image
metadata in the image properties filter.
In host scheduler image_prop_filter, the 'hypervisor_version_requires'
image properties, if available, is compared to the host_state's
hypervisor_version, if available.
hypervisor_version_requires should be added on the image as metadata and
should have a operator and version value.
Examples : ">=6.0", ">6.0, <6.2", ""!=6.1"

Partially Implements blueprint xen-support-for-hypervisor-versions
Cell scheduler changes coming up in another commit.
DocImpact

Change-Id: I6fbf232adf9ac78ebb8ac2985739f163f4517d14
Hyper-v: Change the hyper-v error log for debug when resize failed

The error message is not sufficient enough for debug of hyper-v
when resize error occured, this patch adding the necessary info
in error log.

Change-Id: Ic8ecb8f08139face2c7bdca258de5e719d81833c
Closes-bug: #1238430
Sync lockutils from oslo

d498c42	Fix to properly log when we release a semaphore...
3e3ac0c	Modify lockutils.py due to dispose of eventlet...

Change-Id: I2786527cba16cb4cd94999927e9d7aed2ed99357
Related-Bug: #1235437
Raise an error if module import fails.

Previously a missing module would cause the config file generator
to pass (mostly) silently with only a small message going to
stdout. If we can't import a module that seems like it is a bad
thing so lets just bail.

Change-Id: I391220e1344ba1785bf04654c7c5f52e2e8e82fc
Add block device handling to build_and_run_instance

If we have block device mappings we want to prep them and pass them to
the virt driver spawn method so they can be attached to the instance.
If there's a failure during the instance creation the volumes will get
cleaned up.

A failure to prep the block devices will abort a build because it can't
be built as desired and the failure is not likely to be related to the
compute node itself.

On an instance build failure we make an attempt to clean up the block
devices for the instance.  If that fails we are left in a bad state and
will not attempt to reschedule the instance.

This is one part of a series of patches to build up the
build_and_run_instance method.

Part of bp remove-cast-to-schedule-run-instance

Change-Id: I4f9e3fd0b7bb443406645c1d98e673a4d3624b58
Allow _sync_power_states periodic task to hit slave DB

This commit allows those who have slave_connection configured
to have reads from _sync_power_states hit that connection. This
change does not affect anyone who doesn't have a slave. The
behavior remains the same for them.

Implements: blueprint periodic-tasks-to-db-slave
Change-Id: Iaeb2d47a5064a649f427b18d5cbd2b6b97ce90d0
Correct update extension point's check_func for v3 server's controller

When loading update extension point, it should check the extension has
'server_update' function. But current code check with wrong function
name 'server_resize'. And this patch adds testcase for servers extension
point.

Change-Id: I2bee7ff306b3337d24047e471fac9485fec9a6f7
Closes-bug: #1240351
Enable extension access_ips for v3 API

This patch enable extension access_ips, remove old 'access_ip_*'
attributes and related unittest from servers core. And remove
old attributes from api samples.

Partially implements bp nova-v3-api

DocImpact

Change-Id: Id4c8bb721550e317e0695d7876e2faa3d6e91a60
Fix tests to work with mysql+postgres concurrently

Optimise tests.db.test_migrations and tests.db.test_migration_utils for
concurrency and make opportunistic tests obey walk_style configurations.

Closes-Bug: 1207750

Change-Id: Idb30f144fb67aefc58749897d774103c3c0ec640
xen tests: replace assertEquals with assertEqual

In Python 2.6, both assertEqual and assertEquals are
convenience aliases to failUnlessEqual.

In Python 3, failUnlessEqual is explicitly deprecated.

This is part of blueprint assertequal

Change-Id: I570ba5096289538d2364b44f2cdc2ac7ac0a527b
clean up numeric expressions with byte constants

Replace numeric expressions with constants in nova/virt
to make code more readable.

Implements: blueprint byte-unit-clean

Change-Id: I71aba00ac3c33931082cf0402e4b68764caa0212
network tests: replace assertEquals with assertEqual

In Python 2.6, both assertEqual and assertEquals are
convenience aliases to failUnlessEqual.

In Python 3, failUnlessEqual is explicitly deprecated.

This is part of blueprint assertequal

Change-Id: I2184bcb14a5bfc413bc78a884c5a9b681c39ac99
Claim IPv6 is unsupported if no interface with IPv6 configured

When IPv6 is supported by glibc but no interface
is configured to use ipv6 (because the ipv6 module
is not loaded), skip ipv6 related checks.

Change-Id: I15aaf3d01f0f51bdc0bd29f30728ca2ab8b5c30a
Make security_group_rule_get_by_security_group() honor columns

This makes the above-mentioned method take a columns_to_join
parameter, which lets us control it preloading behavior.

Related to blueprint compute-manager-objects

Change-Id: Ie2404633045c4ebac74225a44cbb609cf4c70887
Add InstanceList.get_by_security_group()

This provides a way to get a list of instances that are in a given
security group. This alternative to SecurityGroup.instances is
much simpler and avoids the potential for passing around a
SecurityGroup object with a ton of Instance objects attached.

Related to blueprint compute-manager-objects

Change-Id: Iea282ea3559da00a03121d6eff59125a5fbae0b2
Merge "Allow _sync_power_states periodic task to hit slave DB"
Merge "Raise an error if module import fails."
Imported Translations from Transifex

Change-Id: Ic634aa2cd5a7c9079a9d261a40961532e9bab35e