Partial oslo-incubator sync

Generated with:
python update.py --base nova --dest-dir ~/Develop/tmp/nova/ --modules
timeutils,sslutils,importutils,memorycache,strutils,context,fileutils,versionutils,systemd

context:
 9b73877 Add a RequestContext.from_dict method
 85d1ce6 Python 3: enable tests/unit/middleware/test_request_id.py
fileutils:
  2b966f9 Fix deletion of cached file for policy enforcer
gettextutils:
 3d90045 Backport code for i18n to check lazy at runtime
jsonutils:
 ef37e03 Added missing jsonutils.dump() function
log:
 5cac11d Merge "Add default log level for websocket"
 433fa0b Make logging_context_format_string optional in log.set_defaults
 ac92c06 Add default log level for websocket
 0aa2bd4 Merge "Ability to customize default_log_levels for each project"
 5fd77eb Ability to customize default_log_levels for each project
 i4d9328c Python 3: enable tests/unit/test_log.py
 722f418 Merge "update new requests logger to default WARN"
 cb5a804 Move `mask_password` to strutils
memorycache:
 90ae24b Remove redundant default=None for config options
 297d772 Raise exception when importing memcache error
strutils:
 cb5a804 Move `mask_password` to strutils
systemd:
 17c4e21 Fix docstring indentation in systemd
 667d1ba Fixed spelling error - occured to occurred
versionutils:
 a2ad3a2 Allow deprecated decorator to specify no plan for removal
 05ae498 Add JUNO as a target to versionutils module

Change-Id: I9e8e8e9b15075d99cf394170c6f5300e7bd0d4cc
Add differencing vhdx resize support in Hyper-V Driver

Differencing VHDX images can be resized, unlike differencing VHD images.
Even so, the Nova Hyper-V driver currently does not support this.

This feature is required for resizing existing instances which use CoW
VHDX images and also in order to resize the root disk image when
spawning a new instance.

The methods which get the internal maximum size of a vhd/vhdx
image have been updated to lookup the parent disk and get the according
size instead of raising an exception in case of differencing images.

Change-Id: I867a9b35e5273b96afc443e5c436a15d0c45161b
Implements: blueprint add-differencing-vhdx-resize-support
Check for resize path on libvirt instance delete

If an instance is deleted after the instance's disk image path has
been renamed by adding the "_resize" suffix to it but before the
resize operation completes, the libvirt driver will not delete the
orphaned files and manual intervention is needed to get them deleted.

This fix addresses the issue by attempting to rename the instance path
by adding a "_del" suffix and if that fails, renaming the instance path
with the "_resize" suffix by replacing the "_resize" suffix with the
"_del" suffix.  If both renaming operations fail, the sequence is
repeated, in case the the disk image path initially had the "_resize"
suffix and another thread removed it before the second rename operation
was attempted. These rename operations are used in favor of checking
for the existence of paths and deleting if found, because rename
operations are atomic whereas another thread could rename the path
between the exist check and the deleting.

Regardless of the outcome of the renaming operations, the existence of
the instance path with the "_del" suffix is verified and if it exists,
it is deleted. This is done in case a prior delete operation that
managed to create the "_del" path was subsequently interrupted before
all instance files could be deleted.

Note that the LibvirtConnTestCase.test_delete_instance_files test case
was removed in order to eliminate redundancy.

Closes-Bug: #1308565

Change-Id: Ifcb2e18211347ccf3e5472779c5917a729a6eced
libvirt: add parsing of NUMA topology in capabilities XML

Introduce classes to nova.virt.libvirt.config for parsing
the NUMA topology information in the capabilities XML
schema.

Blueprint: virt-driver-numa-placement
Change-Id: I4948514cf38268663cdcf4bb31f335a19a7ec9d1
Raise NotImplemented default-security-group-rule api with neutron

Neutron currently does not implement the nova extension
default-security-group-rule which allows an admin to set which rules are in
the default security group when a tenant is onboarded. Implementing this
type of functionality should be done in neutron directly as proxying the
api calls to do this from nova is not possible as neutron creates the
default security group itself. Previously, if one tried to use this api
with neutron a 500 error was raised, now a 501 error is raised.

Change-Id: I6d1bb1c9c2d79278a85b96aea800b4b1f3489225
Closes-bug: 1326958
Merge "Add differencing vhdx resize support in Hyper-V Driver"
Merge "Partial oslo-incubator sync"
Merge "libvirt: add parsing of NUMA topology in capabilities XML"
Merge "Raise NotImplemented default-security-group-rule api with neutron"
Merge "Check for resize path on libvirt instance delete"