Skip to content
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

Fix bug where mysql table row stats were not being collected #12472

Merged
merged 1 commit into from
Jul 8, 2022

Conversation

jmeunier28
Copy link
Contributor

@jmeunier28 jmeunier28 commented Jul 7, 2022

What does this PR do?

Follow up to this PR #11043

Updates metadata.csv to reflect correct metric name, mysql.info.table.rows.changed and fixes the table_rows_stats_metrics config option look up, so metrics are properly reported

Motivation

Additional Notes

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • PR title must be written as a CHANGELOG entry (see why)
  • Files changes must correspond to the primary purpose of the PR as described in the title (small unrelated changes should have their own PR)
  • PR must have changelog/ and integration/ labels attached

@jmeunier28 jmeunier28 requested review from a team as code owners July 7, 2022 23:20
@ghost ghost added the integration/mysql label Jul 7, 2022
@@ -401,6 +401,7 @@ def _collect_metrics(self, db, tags):

if is_affirmative(self._config.options.get('table_rows_stats_metrics', False)) and self.userstat_enabled:
# report size of tables in MiB to Datadog
self.log.debug("Collecting Table Row Stats Metrics.")
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jmeunier28
Copy link
Contributor Author

jmeunier28 commented Jul 7, 2022

here are the metrics being reported on our test database

Screen Shot 2022-07-07 at 4 31 58 PM

note: its a monotonic count and table:info rows_changed never changes (its stuck at 10k) so thats what its reporting 0 here

@codecov
Copy link

codecov bot commented Jul 7, 2022

Codecov Report

Merging #12472 (47ac0be) into master (f354c7c) will increase coverage by 0.01%.
The diff coverage is 50.00%.

Flag Coverage Δ
mysql 88.03% <50.00%> (+0.52%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

@ofek ofek merged commit 0469419 into master Jul 8, 2022
@ofek ofek deleted the jmeunier/add-debugging branch July 8, 2022 02:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants