def start(self): # Spawn the thread # Pass the Que as last argument so that in case of exception, the # daemon can exit gracefully. fixme(padkrish) thr_q = utils.EventProcessingThread("VDP_Mgr", self, 'process_queue') thr_q.start() task_err_proc = utils.PeriodicTask(constants.ERR_PROC_INTERVAL, self.process_err_queue) task_err_proc.run() task_uplink = utils.PeriodicTask(constants.UPLINK_DET_INTERVAL, self.vdp_uplink_proc_top) task_uplink.run()
def start_rpc_task(self): thrd = utils.EventProcessingThread('Agent_RPC_Server', self, 'start_rpc') thrd.start() return thrd
def create_thread(self): """Create a task to process event for updating iptables.""" ipt_thrd = utils.EventProcessingThread('iptables', self, 'process_rule_info') return ipt_thrd