Distributed Systems Pattern: Lease

This post was originally published on this site

Martin Fowler

A cluster node can ask for a lease for a limited period of time, after which it expires. The node can renew the lease before it expires if it wants to extend the access. Implement the lease mechanism with Consistent Core to provide fault tolerance, and consistency. Have a ‘time to live’ value associated with the lease. Cluster nodes can create keys in a Consistent Core with a lease attached to it. The leases are replicated with the Leader and Followers to provide fault tolerance. It’s the responsibility of the node which owns the lease to periodically refresh it. HeartBeat is used by the clients to refresh the time to live value in the consistent core. The leases are created on all the nodes in the Consistent Core, but only the leader tracks the lease timeouts. The timeouts are not tracked on the followers in the Consistent Core. This is

To read the full article click on the 'post' link at the top.