BigFav/MegaCron — pull request #30 by umzegher (2014-03-06 00:33:13+00:00)
Title: Merge worker and scheduler into one daemon

There is now only one script (daemon.py) to be run. It will always perform the tasks of a worker, but if it meets the requirements to be a scheduler it will also perform those tasks. The worker that has been running the longest (lowest id) will become the scheduler. Every worker will watch to see if the scheduler goes down and if it does, the next oldest one will become the new scheduler. I think that this is easier than performing an election and I can't think of any downsides to this approach. If you can think of any please let me know.