-
Notifications
You must be signed in to change notification settings - Fork 763
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rewrite processlist collector #603
Conversation
6f4c12b
to
a5a6dc0
Compare
Thanks! One question, this drops the |
Yea, looks like it's from some very old MySQL. Normally, it shouldn't do anything useful but being present :) |
Signed-off-by: Roman Vynar <roman.vynar@quiq.com>
a5a6dc0
to
4bbd404
Compare
Signed-off-by: Roman Vynar <roman.vynar@quiq.com>
Looks like there are some unrelated mixin errors. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some issues with the metric names.
Signed-off-by: Roman Vynar <roman.vynar@quiq.com>
You are right. I corrected the names and the description about breaking changes on the first post. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, Thanks!
BREAKING CHANGES: Metric names in the info_schema.processlist collector have been changed. #603 Metric names in the info_schema.replica_host collector have been changed. #496 * [CHANGE] Rewrite processlist collector #603 * [FEATURE] Add collector for `replica_host_status` #496 * [ENHANCEMENT] Expose dates as timestamps grom GLOBAL STATUS #561 * [BUGFIX] Fix mysql_slave_hosts_info for mysql 5.5 and mariadb 10.5 #577 * [BUGFIX] Fix logging issues #562 #602 Signed-off-by: SuperQ <superq@gmail.com>
BREAKING CHANGES: Metric names in the info_schema.processlist collector have been changed. #603 Metric names in the info_schema.replica_host collector have been changed. #496 * [CHANGE] Rewrite processlist collector #603 * [FEATURE] Add collector for `replica_host_status` #496 * [ENHANCEMENT] Expose dates as timestamps grom GLOBAL STATUS #561 * [BUGFIX] Fix mysql_slave_hosts_info for mysql 5.5 and mariadb 10.5 #577 * [BUGFIX] Fix logging issues #562 #602 Signed-off-by: SuperQ <superq@gmail.com>
BREAKING CHANGES: Metric names in the info_schema.processlist collector have been changed. #603 Metric names in the info_schema.replica_host collector have been changed. #496 * [CHANGE] Rewrite processlist collector #603 * [FEATURE] Add collector for `replica_host_status` #496 * [ENHANCEMENT] Expose dates as timestamps grom GLOBAL STATUS #561 * [BUGFIX] Fix mysql_slave_hosts_info for mysql 5.5 and mariadb 10.5 #577 * [BUGFIX] Fix logging issues #562 #602 Signed-off-by: SuperQ <superq@gmail.com>
BREAKING CHANGES: Metric names in the info_schema.processlist collector have been changed. #603 Metric names in the info_schema.replica_host collector have been changed. #496 * [CHANGE] Rewrite processlist collector #603 * [FEATURE] Add collector for `replica_host_status` #496 * [ENHANCEMENT] Expose dates as timestamps grom GLOBAL STATUS #561 * [BUGFIX] Fix mysql_slave_hosts_info for mysql 5.5 and mariadb 10.5 #577 * [BUGFIX] Fix logging issues #562 #602 Signed-off-by: SuperQ <superq@gmail.com>
BREAKING CHANGES: Metric names in the info_schema.processlist collector have been changed. #603 Metric names in the info_schema.replica_host collector have been changed. #496 * [CHANGE] Rewrite processlist collector #603 * [FEATURE] Add collector for `replica_host_status` #496 * [ENHANCEMENT] Expose dates as timestamps grom GLOBAL STATUS #561 * [BUGFIX] Fix mysql_slave_hosts_info for mysql 5.5 and mariadb 10.5 #577 * [BUGFIX] Fix logging issues #562 #602 Signed-off-by: SuperQ <superq@gmail.com>
The example grafana dashboard still uses some old metric names (I didn't checked the other ones) |
mysql_info_schema_threads_seconds > mysql_info_schema_processlist_seconds see prometheus/mysqld_exporter#603
fix(mariadb): rename metric in alert mysql_info_schema_threads_seconds > mysql_info_schema_processlist_seconds see prometheus/mysqld_exporter#603
fix(mariadb): rename metric in alert mysql_info_schema_threads_seconds > mysql_info_schema_processlist_seconds see prometheus/mysqld_exporter#603
Remove DATA_SOURCE_NAME secret, use MYSQLD_EXPORTER_PASSWORD and constructed mysqld.address option Update alerts: The metric mysql_info_schema_threads_seconds has been renamed to mysql_info_schema_processlist_seconds with exporter v0.14.0+ see prometheus/mysqld_exporter#603
Remove DATA_SOURCE_NAME secret, use MYSQLD_EXPORTER_PASSWORD and constructed mysqld.address option Update alerts: The metric mysql_info_schema_threads_seconds has been renamed to mysql_info_schema_processlist_seconds with exporter v0.14.0+ see prometheus/mysqld_exporter#603
Remove DATA_SOURCE_NAME secret, use MYSQLD_EXPORTER_PASSWORD and constructed mysqld.address option Update alerts: The metric mysql_info_schema_threads_seconds has been renamed to mysql_info_schema_processlist_seconds with exporter v0.14.0+ see prometheus/mysqld_exporter#603
Hello,
Rewritten processlist collector to include both Command and State columns and stop doing state remapping.
Couple of reasons for this:
The old re-mapping is not accurate, somewhat outdated and requires constant maintaining. With this PR, we won't bother about thread state mapping and it will flexible for anyone to do what they want to do on the expression side.
As you can see it is not always an execution phase of regular queries but a whole bunch of stuff that we may want to exclude for alerting and which is the normal thing, for say Group Replication waiting_for_handler_commit (it is a phase of group commit where it is waiting and not consuming CPU) as opposite to the user queries (consuming CPU).
It becomes very handy when we want to sum all queries and exclude some particular states, or just see on the graph how those state are distributed to decide what to do.
Breaking changes:
Also added a test.
There is a similar PR #442 but it just adds "command" and retains the state remapping.
Another PR #381 complaining about remapping.
Sample output: