shatteredsilicon / ssm-submodules

GNU Affero General Public License v3.0
1 stars 2 forks source link

MySQL Replication page is not working properly with multiple source replication #159

Closed oblitorum closed 1 year ago

oblitorum commented 1 year ago

When selecting a slave host with multiple master defined on the MySQL Replication page, the dashboards on that page are not working properly. e.g.

image

To solve this, we may need to have an additional selection drop-down for each named replication slave thread, next to the HOST drop-down.

cc @jonathanvx @gordan-bobic

gordan-bobic commented 1 year ago

I think an extra drop-down with each thread would be good.

But we should be able to also have the "all" default option which: 1) Shows IO / SQL threads running as No only if any of the defined threads are not running. 2) Replication error no should show the most recent error, if any threads show an error. 3) Replication lag should show one line on the graph per replication thread. 4) Binlog size / written should also be stacked graphs showing all replication threads.

Individual replication thread views should work as they do now.

oblitorum commented 1 year ago

Copied that

oblitorum commented 1 year ago
  1. Binlog size / written should also be stacked graphs showing all replication threads.

I'm a liitle confused about this point, you mean when we're exploring the slave instance on this page, we should show all its masters' binlog graphs? In this case, the mysqld_exporter is running on the slave instance, it needs extra DSNs of its masters to connect to and get the binlog data with SHOW BINARY LOGS;.

Or you mean we show the binlog of this slave instance only, but split it into different masters, e.g. there are 2 masters, it should show 2 lines/graphs as the binlog data from each master? But is it possible to tell what data comes from which master? I checked the mariadb doc, didn't find the solution.

gordan-bobic commented 1 year ago

You are right, what I said made no sense. What I meant to say is not a stacked graph for binlog (there is only one binlog) but a stacked graph for relay logs. Every slave thread has its own relay log.

oblitorum commented 1 year ago

Ah, I see. The relay logs graphs are shown on the bottom of that page, just made them shown with all replication threads.

image

gordan-bobic commented 1 year ago

Yes, exactly.