[MCOL-4556] master detection not work properly in cmapi Created: 2021-02-24 Updated: 2021-06-28 Resolved: 2021-03-09 |
|
| Status: | Closed |
| Project: | MariaDB ColumnStore |
| Component/s: | cmapi |
| Affects Version/s: | None |
| Fix Version/s: | cmapi-1.3 |
| Type: | Bug | Priority: | Major |
| Reporter: | Richard Stracke | Assignee: | Todd Stoffel (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
Hello, cmapi detects master with SELECT VARIABLE_VALUE FROM information_schema.GLOBAL_STATUS WHERE VARIABLE_NAME = 'SLAVE_CONNECTIONS'; SLAVE_CONNECTIONS is defined as "Number of REGISTER_SLAVE attempts. In practice the number of times slaves has tried to connect to the master. " https://mariadb.com/kb/en/replication-and-binary-log-status-variables/#slave_connections It is a counter, which will not be reseted, if the server is no master anymore, so this will not safely detects a master.
Maybe the suggestion from Todd in
|
| Comments |
| Comment by Richard Stracke [ 2021-02-26 ] | |||||
|
SLAVE_CONNECTIONS counts calls of COM_REGISTER_SLAVE,
Added here; I see no codepart, where it ever will be decreased, also reset status; will not help. |