This is a simple example appliation that uses etcd to co-ordinate and select a leader.
This is a nice, quick and dirty for simple leader election within a etcd cluster and how to use the python-etcd library.
This has been tested and is/hopefully currently exposed on ctpug.rationalproducts.co.za.