What is Replication?
Copying data continuously across multiple database nodes to improve read throughput, availability, and durability against server failure.
Definition
Replication keeps copies of the same data on multiple nodes. In the common primary–replica setup, all writes go to the primary, which streams changes — PostgreSQL's WAL shipping, MySQL's binlog — to replicas serving read traffic. Asynchronous replication is fast but risks losing the last few transactions on failover; synchronous replication guarantees durability at a latency cost. Replicas also introduce replication lag, so an app may read stale data moments after writing. Multi-primary systems like Cassandra accept writes anywhere and reconcile conflicts. Replication buys availability and read scale; sharding buys write scale.

