Details
-
New Feature
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
-
None
-
MXS-CAPACITY-26-3
Description
GaleraMon selects just one Master/Write-node, as this keeps things simple for routers, and is generally a good idea. Writing to multiple Galera nodes could easily cause conflicts. GaleraMon currently selects the server with lowest wsrep_local_index (Galera setting), or alternatively the one with lowest priority (MaxScale setting) as writable. Raft-mode selects the leader as writable.
When using Raft with a geographically distributed Galera cluster, it may be advantageous to instead write to the closest node (at least for trx with multiple queries in them). With this in mind, it would be easier to the DBA if GaleraMon had an enum-setting that defined the write-node selection strategy. It could even be an enum list, allowing multiple criteria to be listed.
Possible criteria:
- Node with least latency as primary write nod
- A specific node (name in MaxScale config)
- Galera index
- Raft leader
idea2:
allow user to define /mark which nodes are allowed to be writable (leader, follower, least latency)
Galera nodes do allow read/write to all nodes and the new maxctrl list servers should reflect that unless we've configured routing to node index 0, in which case only 1 of the nodes is writable.
Maxscale read write state for servers should reflect their configuration.