Prevent nova services' coverage data from combining into nova-api's

Now if combining a coverage report once, nova services' coverage
data are combined into nova-api's.
This renames nova-api coverage datafile to .nova-coverage.api and
creates a new coverage instance to combine when reporting.

Fixes bug: 1152475

Change-Id: I90b6535d490cf0123a127f8752986edd782ef37e
Fix Hyper V instance conflicts

Fixes bug 1152368

If the hyperv driver attempts to boot an instance and a previous
instance with the same name was not properly removed, the boot will
fail due to an error creating root.vhd.  This only happens when
using CoW images.  This fix deletes the instance directory before
creating the new instance so that there will never be an old image
to interfere with creation of the new one.

This is most likely to be an issue in development and test
environments that toggle between versions of nova with no migration
path.

Change-Id: I21eab01590c426234b4b9a55abec4b2d2df0e168
xenapi: rpmbuild fixes

Fixes bug 1157695

This fix removes the parted dependency from the rpm specification file,
and also gets rid of the assumption, that the build-rpm.sh is executed
at a specific directory.

Change-Id: I1dcf9096a783a88bc09af0f4f4d5541a7e505748
Fixes argument order of quantumv2.api.get_instance_nw_info

Fixes bug #1159042

Change-Id: I04136707cdf2ca716dabd92aa7a471c291a3b4eb
Make iptables drop action configurable.

Resolves bug 1013893 by allowing the setting of the iptables drop
action with a configuration flag. It is expected that this would be
used for run a LOGDROP action before actually dropping the packet.

DocImpact: the drop action for iptables rules can now be configured
for nova-network users with the iptables_drop_action flag.

Change-Id: I15720d2742955611929a4d7181a269795296e025
Fix /servers/<instance-id>os-security-groups using quantum

When using quantum security groups:
	GET /servers/<instance-id>/os-security-groups
aways returns an empty list. This patch adds a call to
get_instance_security_groups in the api implemenation of security groups.
This method passes both the instance_id and instance_uuid so the api layer
does not need to be aware of which underlying implementation is being used.
The instance_id is needed when using nova and when using quantum the
instance_uuid is needed so both need to be passed.

Fixes bug 1159793

Change-Id: I372adcf93c55d4e6469ef08429ec260d3387f9fe
set up FakeLogger for root logger.

A recent change in openstack.common.log was made such that it
initialized the root logger instead of the project specific logger,
'nova' in this case.  Update the unit tests for this to fix the problem
where unit tests spam the console with log output.

Fix bug 1159978.

Change-Id: Id64a5b078b4024c3269086ed5d64940b3a38ddfa
Add missing tests for db.instance_type_* methods

There was no tests in test_db_api for instance_type_* methods.

Add tests to ensure that all works.
Also these tests allow us to refactor work with session and
to add missing unique constraints.

Fix bug in instance_type_get_all, we shouldn't remove
is_public from input filters dictionary.

blueprint db-api-tests

Change-Id: Ia02d73e6ffd964d6edb605039eb95e9f90ff0482
Remove race condition (in InstanceTypes)

Soft delete all duplicate rows with the same name except one with
the biggest value in `id` column.

Soft delete all duplicate rows with the same flavorid except one with
the biggest value in `id` column.

Create UC on columns (name, deleted) and (flavorid, deleted)

Replace Select then Insert -> Try to Insert.

blueprint db-enforce-unique-keys

Change-Id: If66d2f1387c2b2748784bf7ac9746b8d755b70a9
Add missing tests for db.instance_type_access_* methods

There was no tests in test_db_api for instance_type_access_* methods.

Add tests to ensure that all works.
Also these tests allow us to refactor these methods.
For example add missing unique constraint on columns
(instance_type_id, project_id)

blueprint db-api-tests

Change-Id: Idfeda1685ef8c812c1211783aede15795b0d7caf
Merge "Fix Hyper V instance conflicts"
Adding netmask to dnsmasq argument --dhcp-range

By default, dnsmasq will try to guess the proper subnet size but
sometimes it will fail. This patch provides the network netmask
to dnsmasq via the --dhcp-range argument.

Fixes: bug #1154929

Change-Id: I74d62c837b5310004b9151851697e3ea3b475f92
Make more readable error msg on quantum client authentication failure

Fixes bug 1052495

Change-Id: Ia53d1f1db2b2b720509f29ae70b419f6cfabae17
Always store old instance_type during a migration

Previously, we were trying to optimize for the migration (as opposed
to resize) case by not storing the old_ instance_type. However,
this is confusing to the vast amount of shared code that works on
migrations and resizes because the "is old == new" logic must be
replicated everywhere. To cut our losses and hopefully avoid other
hidden dragons, this patch removes the optimization and makes both
paths the same.

Fixes bug #1160489

Change-Id: I2ad7b02239baada5fd2174f5b61cdc90ec91e6f5
Merge "xenapi: rpmbuild fixes"
Merge "Fixes argument order of quantumv2.api.get_instance_nw_info"
Merge "set up FakeLogger for root logger."
Merge "Make more readable error msg on quantum client authentication failure"
Adds Tilera back-end for baremetal

blueprint add-tilera-to-baremetal.

The baremetal driver is a hypervisor driver for Openstack Nova
Compute. Within the Openstack framework, it has the same role
as the drivers for other hypervisors (libvirt, xen, etc). With
this patch set of tilera-backend, provisioning and management
of non-PXE tilera physical hardware is accomplished using
common cloud APIs and tools.

Change-Id: I356c06a07ace463779e3b84836d5000331e24814
Co-authored-by: Mikyung Kang <mkkang@isi.edu>
Co-authored-by: David Kang <dkang@isi.edu>
Co-authored-by: Ken Igarashi <igarashik@nttdocomo.co.jp>
Co-authored-by: Arata Notsu <notsu@virtualtech.jp>
Co-authored-by: Devananda van der Veen <devananda.vdv@gmail.com>
Merge "Fix /servers/<instance-id>os-security-groups using quantum"