[MXS-3281] r/w split slave_selection_criteria should have none Created: 2020-11-02  Updated: 2021-09-09  Resolved: 2021-09-09

Status: Closed
Project: MariaDB MaxScale
Component/s: readwritesplit
Affects Version/s: None
Fix Version/s: 6.2.0

Type: New Feature Priority: Major
Reporter: Manjot Singh (Inactive) Assignee: Todd Stoffel (Inactive)
Resolution: Won't Fix Votes: 0
Labels: None

Issue Links:
Relates
relates to MXS-3536 max_slave_connections=0 doesn't work ... Closed

 Description   

Add option "none" to "slave_selection_criteria" in readwritesplit to prevent usage of slaves altogether.



 Comments   
Comment by Johan Wikman [ 2020-11-03 ]

So everything should go to master?
Why is readconnroute with router_options=master not applicable?

Comment by Manjot Singh (Inactive) [ 2020-11-03 ]

We should skip query parser overhead as well with this.

Comment by Ben Stillman [ 2020-11-03 ]

toddstoffel Would setting this to "none" bypass the query parsing (thus reduce/eliminate the overhead of read/write split)?

Comment by Christine Lieu (Inactive) [ 2020-12-08 ]

Another way to tackle this would be a much bigger, longer-term project to maybe merge the routers.

Comment by Johan Wikman [ 2020-12-09 ]

Fundamentally they are quite different, RCR being connection oriented and RWS being statement oriented. Once the connection has been established, RCR is in its simplest form basically a switch; it just forwards bytes from one port to another, without any knowledge about the data that is being transferred. However, if a filter that needs to be aware of statements is added to the routing chain that's no longer quite true. The names of both routers are currently rather far from what they actually are; readconnroute suggests that it could only be used for reading, which is not the case, and readwritesplit suggests that it would always do read write splitting, which is not the case if the backend is xpand, although it makes perfect sense to use it nonetheless. If they were renamed as connection oriented router and statement oriented router, the situation would be clearer. Starting from scratch things could be arranged quite differently of course. There could be just a single router, and then for starters you would have to configure whether the backend is chosen at connection creation time or at each statement/transaction boundary. That choice would then affect what other choices you can make.

Comment by markus makela [ 2021-05-06 ]

A simpler approach is to just use max_slave_connections=0 and fix the bug that it currently has where it requires at least one connection.

Comment by markus makela [ 2021-09-09 ]

Is this really needed? Using max_slave_connections=0 already behaves exactly like this. Looks like the fixed issue hasn't been linked to this one: MXS-3536

Comment by Manjot Singh (Inactive) [ 2021-09-09 ]

Can you fix the bug in the previous comment? then it might work.

Comment by markus makela [ 2021-09-09 ]

Since MXS-3536 is fixed in 2.5.12 and this should be redundant, OK if we close this?

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