Cluster

Terms

  • Node
    • A logical member of a cluster. There could be multiple nodes on a physical machine. Defined by a hostname:port:uid tuple.
  • Cluster
    • A set of nodes joined together through the membership service.
  • Leader
    • A single node in the cluster that acts as the leader. Managing cluster convergence and membership state transitions.

Membership Lifecyle

Membership

The cluster membership state is a specialized CRDT, which means that it has a monotonic merge function. When concurrent changes occur on different nodes the updates can always be merged and converge to the same end result.

Network view of a cluster

Initial Cluster State

Deploying 5 nodes

Joining the Cluster

Everyone attempts to Join Seed Nodes

Leader Election

Gossip Protocol begins, marking nodes UP

Ring Formation

Gossip Spreads, Communication stablished with Non-Seed Nodes

Network view of a cluster

Live Demo!

Akka Cluster

By Gabriel Volpe