Adds retry on upload_vhd for xapi glance plugin

Add a retry for the xapi glance plugin to handle transient issues
when uploading the vhd.

An example issue we're seeing is a connection timeout:

['XENAPI_PLUGIN_FAILURE', 'upload_vhd', 'error',
		"(110, 'Connection timed out')"]

To work around transient issues such as a connection timeout, we
should retry based on glance_num_retries before outright failing.

Change-Id: Ice6fdd3dd39ef40e5997d69209aaafa66bff5d6e
Fixes: bug #1134493
Fallback coverage backdoor telnet connection to lo

This commit adds a fallback condition for the telnet connection.
If trying to establish a connection to the backdoor fails with
ECONNREFUSED the extension will then try to connect to the same
port on the lo device. Eventlet backdoors currently open on the
lo interface and this is to cover the common (and CI) use case
where the hostname doesn't resolve to 127.0.0.1.

Using the fallback was done to avoid adding a new config option
to specify that the hostname that is in the DB for the service
doesn't resolve to the lo device, and that the extension should
use just use localhost.

Change-Id: I0321db68cbccf0cddf13d91a77dfb744bb456d87
Compute manager should remove dead resources

While most hypervisors return a single - and constant - value from
driver.get_available_nodes, baremetal does not. When a node is deleted
from the baremetal database, it is no longer returned from
driver.get_available_nodes. However, Nova's compute_node record is not
directly updated.

This patch allows Compute Manager to detect missing nodes within
update_available_resources. It then invokes resource_tracker to update
the dead node and remove it from compute.

This in turn allows the ServiceGroup API to properly update the
servicegroup when a baremetal node is no longer in service.

Fixes bug 1138184

Change-Id: Icfff3f8e3099668806633a6a58a152b32ec8b49b
Merge "Adds retry on upload_vhd for xapi glance plugin"
Merge "Fallback coverage backdoor telnet connection to lo"
Merge "Compute manager should remove dead resources"