Replication lag is a symptom, not a metric

Seconds_Behind_Master is the number everyone alerts on and it measures one thing: how far behind the applying thread is on the transaction it is currently executing. It reads zero while the replica is broken.

SHOW SLAVE STATUSG
-- Seconds_Behind_Master: 0
-- Slave_SQL_Running: No        ← stopped, so nothing is behind
-- Last_SQL_Error: Duplicate entry '8841' for key 'PRIMARY'

Alert on all three: the lag, and both threads running. The lag itself is also measured against the master’s clock at the time the event was written, so a network delay is invisible and a paused replica reports the lag of the transaction it was in the middle of. A heartbeat table written by the master and read by the replica is the measurement that does not lie.