forked from cockroachdb/cockroach
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sqlstats: fix counter for in-memory fingerprints
Problem: The counters used to track the number of unique fingerprints we store in-memory for sql stats were refactored in cockroachdb#110805. In change cockroachdb#110805 a bug was introduced where it incresease the memory instead of resetting the counts. This causes the statstics to stop calculating new stats once the limit is hit. Solution: Fix the bug by resetting the counters instead of increasing them. Added new test to test the reset functionality. Fixes: cockroachdb#111583 Release note (sql change): Fix a bug that causes the sql stats to stop collecting new stats.
- Loading branch information
Showing
2 changed files
with
16 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters