[MXS-1382] Use wsrep_sync_wait to detect replication lag in Galera clusters Created: 2017-08-31  Updated: 2022-09-08  Resolved: 2022-09-08

Status: Closed
Project: MariaDB MaxScale
Component/s: galeramon
Affects Version/s: 2.5
Fix Version/s: N/A

Type: New Feature Priority: Trivial
Reporter: markus makela Assignee: Todd Stoffel (Inactive)
Resolution: Won't Do Votes: 0
Labels: Galera

Epic Link: Monitor Improvements

 Description   

The Galera monitor can detect the lag between certification and application of events in a Galera cluster by writing an event on the write-master node and doing "dirty reads" on the nodes labeled as slaves. This gives similar functionality for Galera clusters that is already in place for Master-Slave clusters in mysqlmon.

Another option is to use wsrep_local_recv_queue as a measurement of lag in a Galera cluster.



 Comments   
Comment by Geoff Montee (Inactive) [ 2020-01-16 ]

Another option is to use wsrep_local_recv_queue as a measurement of lag in a Galera cluster.

ProxySQL already supports something like this:

max_transactions_behind - determines the maximum number of writesets behind the cluster that ProxySQL should allow before shunning the node to prevent stale reads (this is determined by querying the wsrep_local_recv_queue Galera variable).

https://github.com/sysown/proxysql/wiki/Main-(runtime)#mysql_galera_hostgroups

Generated at Thu Feb 08 04:06:19 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.