Remove unused compute_api in extend_status

There are unused compute_api variable in extend_status
extension, this patch remove them in both v2/v3(v2.1).

Change-Id: I901fb3c6bc1c75b66b530a023c8632fb7decede3
Set error state when unshelve an instance due to not found image

If shelve image created by shelve operation can not be found when
unshelve, nova should set the instance error state.

This patch add a new param show_deleted to glance api:
:param show_deleted: (Optional) show the image even the status of
                     image is deleted.

Change-Id: Ie4bc8dfec0922023dd1a4204a67acd77f7bb0498
Closes-Bug: 1371406
Fix nova evacuate issues for RBD

For RBD scenario, there are some issues in Nova code
now against evacuate function:

1. Based on current implementation, nova evacuate and
nova rebuild are sharing some code. When user enables
the on_shared_storage option for nova evacuate, nova
will check if the instance path is accessible. For
the RBD scenario, the volume(block) is shared between
different hosts, though the path isn't shared at the
filesystem level. This patch fixes this issue and adds
test cases for that.

2. Missing the 'recreate' parameter for rebuild method.
Though the libvirt driver doesn't implement rebuild
method(only Ironic driver implements it), but we really
need to set 'recreate' in kwargs so it gets passed to
_rebuild_default_impl so we don't call driver.destroy
on evacuate for shared filesystem/block storage cases.
It is fixed in this patch and test case is added as well.

Closes-Bug: 1249319
Closes-Bug: 1340411

Change-Id: Idc8c45b055e986cf85730235d5d25777632ad1c1
Split out PCI passthrough filter unit tests

Breaks out the PCI passthrough filter unit tests from
test_host_filters.py into their own test file, and uncrufts from stubout
to mock in the process.

Change-Id: I40bc7ae1a691b447b18cc75b9f615f3f7435988f
Split and fix availability zone filter unit tests

The availability zone filter unit tests were broken, but the problem
with them was being masked due to aggregate fixtures that were created
in tests that happened to be alphabetically ordered right before them.
This patch splits out these unit tests into their own file and mocks out
the appropriate call to nova.db.aggregate_metadata_get_by_host() instead
of relying on database records.

Change-Id: Ic692d3e7c77047ae6d901b955bc504fdc5e73738
Updated from global requirements

Change-Id: I11c99071cab59458a093485aa903b5fff9b8c1d5
Port SecurityGroupRules controller into v2.1

This patch port SecurityGroupRules controller into v2.1 security_groups extension.

This patch just move the v2 code into v2.1 and share the unittest. The other
v2.1 related fix and improvement will be addressed by subsequent patchset.

Partially implements blueprint v2-on-v3-api

Change-Id: I23c6d7c70ec27068066e2a2e3c7764982bf8ed1d
Port security-group-default-rules extension into v2.1

This patch port security-group-default-rules into v2.1.

This patch just move the v2 code into v2.1 and share the unittest. The other
v2.1 related fix and improvement will be addressed by subsequent patchset.

Partially implements blueprint v2-on-v3-api

Change-Id: I4d65993d6413160d2c7c2eb2ce0c3f66768e1a36
Use 404 instead of 400 when security_group is non-existed

This patch correct the status code when security_group is
non-existed. This is good for sharing unittest between v2.1
and v2 API.

Change-Id: Ib4bd725381052947859db1ab30905fa33e502679
Fixes DOS issue in instance list ip filter

Converts the ip filtering to filter the list locally based
on the network info cache instead of making an extremely expensive
call over to nova network where it attempts to retrieve a list
of every instance in the system.

Change-Id: I455f6ab4acdecacc5152b11a183027f933dc4475
Closes-bug: #1358583
libvirt: introduce config to handle cells memory pages caps

Introduces a new config 'LibvirtConfigCapsNUMAPages' to
the driver libvirt which handles memory pages capabilities
of the host in the context of NUMA.

Work-item: Enhance libvirt driver to report available
           large pages per NUMA node in the host state data

Partial-Implement: blueprint virt-driver-large-pages
Change-Id: I902510c190a1b85d860f2579b01b52bb13f4d034
Merge "Updated from global requirements"
Small doc fix in compute test

Change-Id: Id7b5559e985936091a723e2d9cb4c342ea948f71
Merge "Fixes DOS issue in instance list ip filter"
Fix nova-compute start issue after evacuate

After evacuated successfully, and restarting the failed
host to get it back, Nova will call init_host() and then
call method _destroy_evacuated_instances(). In method
_destroy_evacuated_instances(), nova will check again if
the storage is shared or not to decide if the storage
should be destroyed. Now nova is using temp file to check
if it's shared file system, but it's wrong for RBD case.
So Nova will attempt to delete the shared block storage,
which will fail since it's used by the new instance. This
patch fixes this issue and adds test cases for that.

Closes-Bug: 1385484

Change-Id: I71bb818f3c2930b3a2ddf1817dfd4bb61fae7e98
Merge "Split out PCI passthrough filter unit tests"
Merge "Fix nova evacuate issues for RBD"
Merge "Fix nova-compute start issue after evacuate"
Merge "Remove unused compute_api in extend_status"
Merge "Set error state when unshelve an instance due to not found image"