Implement sync_power_state periodic task

Implement a periodic task in the ConductorManager which will check all
the existing, non-locked nodes and verify that their current power
states correspond to state stored in DB. If they differ, for now, log a
warning and update the DB using current power state.

This is a step towards keeping powered-off-nodes off.

Also, this removes the unused db.api.get_nodes method
and adds a new get_nodeinfo_list method.

Change-Id: I609fdbd7db6620de617b44f83c7ec35350f9178c
Blueprint: keep-powered-off-nodes-off
Add power control to PXE driver

Necessary node power control added to PXE driver.
Power control code moved to separate module for
usage in manager and drivers. Reboot handling added
to power control code.

Partially implements: blueprint pxe-mount-and-dd
Change-Id: Ic13c046c621211d9c1533325812955233441d2da
Merge "Implement sync_power_state periodic task"
Import heartbeat_interval opt in API

The API for /v1/drivers needs to read the conductor.heartbeat_timeout
option from ironic.conductor.manager in order to get the list of
active conductor drivers from the database.

Change-Id: If6abd41ac01b3704bbdda0212d07abcaa0339ef9
Closes-bug: 1258207
Merge "Add power control to PXE driver"
Expose created_at/updated_at properties in the REST API

Ironic client display created_at/updated_at values, but API does not
return these fields, so node-show display empty value always. With
this fix, we will add created_at/updated_at two fields into API base
class to enable all API to support these two fields, including node,
port and chassis now.

Closes-Bug: #1244072
Change-Id: I03f935902a86fac2f8fb58703c72ca0fda84843b
Correct error with unicode mac address

correct TypeError: translate() takes exactly one argument (2 given) from
_normalize_mac function when passed a unicode mac address. Also add test
to check that it works.

Change-Id: Ibc04de2a8318e1a4a3bed4108623854bdcee371b
Merge "Correct error with unicode mac address"
Merge "Expose created_at/updated_at properties in the REST API"