Move `utils.hash_file` -> `imagecache._hash_file`

`hash_file` is only used by `imagecache` so it doesn't make sense (yet) for it
to be included in utils.

Change-Id: I2f4d1deb03e4afceb911ef4b6d6ae6760ddca225
Fixes typos in the files in the nova folder

blueprint fix-nova-typos

Change-Id: I0971b98999381183c0c77fff1d569180606e338b
Fixes typos in nova/db code

blueprint fix-nova-typos

Change-Id: Ie2e9447790468aee14c6baee679c53d183c69f62
Fixes typo in ListTargets CLI in hyperv driver

Closes-bug: 1237432
Change-Id: Ie7b4cd744e2a4869a84ab42ad1a434628e39a3e6
VMware 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: I4121817277c11e82e0ed63ef8bd1c1e4c951a018
hyperv 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: I9c61bb5b3b6bd40018371aa5f17a3a96cff41a55
Log which filter failed when on log level INFO

If log level is set to INFO,only see a log message about nova-schedule
attempting to build n instances then a log message about setting the
state to error when the scheduler fails to schedule an instance due to
a filter returning 0 hosts.It may be useful to see which filterreturns 0
host for operator.

Close-bug: #1226334

Change-Id: I7564a8ab093895d1f9db357009aac294783a808b
Xenapi: set hostname when performing a network reset

The hostname is removed from the metadata on Xen to address an
issue where windows instances get renamed on reboot. This
becomes a problem when a network reset is called for instances
using the agent communication mechanism. In that case the
agent will incorrectly rename the host. Thus the
hostname needs to be set prior and cleared after a network reset.

The setting of the metadata params also need to be atomic so
locking was added that matches to the locking provided by
other data (network metadata).

Fixes bug 1236877

Change-Id: I473870994c826f85a7c6ec1448171c4e4ee40ff0
Remove instance_info_cache_update() from conductor

After network api was converted to use InfoCache object it no longer
depends on the conductor instance_info_cache_update() method.

This change removes this method from conductor and in addition removes
conductor parameter in calls to network api from within compute manager,
previously needed by the @refrech_cache() decorator in network api for
its calls to this same conductor method.

Change-Id: I5bb535062b5f5948e2b6ba1daa089f3d93471394
Merge "hyperv tests: replace assertEquals with assertEqual"
Merge "Fixes typo in ListTargets CLI in hyperv driver"
Merge "Log which filter failed when on log level INFO"
Merge "Move `utils.hash_file` -> `imagecache._hash_file`"
Merge "Fixes typos in nova/db code"
Merge "Fixes typos in the files in the nova folder"
Merge "Xenapi: set hostname when performing a network reset"
Merge "Remove instance_info_cache_update() from conductor"
Merge "VMware tests: replace assertEquals with assertEqual"
xenapi: make _migrate_disk_resizing_up use @step

Make use of the step decorator into _migrate_disk_resizing_up to make it
more consistent with _migrate_disk_resizing_up.

Also add some extra unit tests to help lock down this process with unit
tests.

Part of blueprint xenapi-migrate-ephemeral-disks
Change-Id: I395b8e27380649c667bb8d891802532ee3ab746b
xenapi: revert on _migrate_disk_resizing_up error

_migrate_disk_resizing_up now follows similar pattern to
_migrate_disk_resizing_down.

This involves using the @step decorator to report progress and rolling
back if any errors occur while migrating the disks to the destination
host.

Part of blueprint xenapi-migrate-ephemeral-disks
Change-Id: I2557357a4f3502f991a5d187c2ecf7ffeb22286e