'Define a periodic task in the stack threadgroups.
The task is run in a separate greenthread.
Periodicity is cfg.CONF.periodic_interval'

def add_timer(self, stack_id, func, *args, **kwargs):

    if (stack_id not in self.groups):
        self.groups[stack_id] = threadgroup.ThreadGroup()
    self.groups[stack_id].add_timer(cfg.CONF.periodic_interval, func, *args, **kwargs)
