QA
Intermediate LevelSystem Design & Architecture

What is the Gossip Protocol and how does it maintain cluster membership in Cassandra?

❓ Interview Prompt: Explain Gossip Protocol, decentralized peer-to-peer cluster state sharing, exponential convergence, and failure detection in Cassandra.

The Gossip Protocol is a decentralized peer-to-peer communication protocol used in distributed databases (Apache Cassandra) to maintain cluster membership and detect node failures:

How Gossip Works:

1
Every second, each cluster node selects a random neighbor node and exchanges state data.
2
State changes (node additions, crashes, schema updates) spread exponentially across the entire cluster in $O(\log N)$ time.
3
Failure Detector: Uses $\Phi$-Accrual Failure Detector to evaluate node responsiveness adaptively.

Code Implementation Example

json
{
  "protocol": "Gossip Protocol",
  "clusterState": "Peer-to-Peer (Decentralized)",
  "gossipInterval": "1000ms",
  "convergenceTime": "O(log N) rounds"
}
πŸ’‘Gossip Protocol cluster configuration specification payload.
🎯 Interview Key Takeaway

Use the Gossip Protocol for decentralized peer-to-peer state propagation and failure detection in large database clusters.

#System Design#Gossip Protocol#Cassandra#Cluster Membership#Intermediate
Back to all System Design & Architecture Questions→

More System Design & Architecture Interview Questions

Beginner LevelSystem Design & Architecture

Explain the CAP Theorem and PACELC Theorem with real-world database examples.

Beginner LevelSystem Design & Architecture

What is Vertical Scaling (Scale Up) vs Horizontal Scaling (Scale Out)?

Beginner LevelSystem Design & Architecture

How do Load Balancers distribute traffic (Round Robin, Least Connections, IP Hash)?