control:actions: Add timer based actions

The timer based actions action starts and stops a timer that runs a list
of actions whenever the timer expires. The configured timer is set to
callback the list of actions against the given zones and any configured
groups.

Where any group does not have a configured value to be compared against,
the groups' service owned state is used to start/stop the timer. When
any service providing a group member is not owned, the timer is started
and if all memebers' services are owned, the timer is stopped.

Where all groups have a configured value to compare against, that will
be compared against all memebers within each group to start/stop the
timer. When all group members have a given value and it matches what's
in the cache, the timer is started and if any do not match, the timer is
stopped.

Basic event config using this action:
.
.
"actions": [
  {
  "name": "call_actions_based_on_timer",
  "timer": {
    "interval": 5000000,
    "type": "repeating"
  },
  "actions": [
    {
    "name": "test"
    }
  ]
  }
]

Change-Id: Ibb80af3218b3cda8b1a7f5bc4dd31046ea6b2bea
Signed-off-by: Matthew Barth <msbarth@us.ibm.com>
3 files changed