Scheduler locking

Locking each iteration of scheduler i.e. fetching -> executing policies -> deleting so that other node does not process same set of events. If the lock is not got, we silently not do anything and wait for next iteration.