-
Notifications
You must be signed in to change notification settings - Fork 21
CNDB-16123: Add slow query logger execution info to non-SAI read commands #2147
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
Conversation
Checklist before you submit for review
|
1a79988 to
667ae3b
Compare
|
I've included a small microbenchmark, these are the results: The cost of generating the extended execution info is 3x greater, but it's still very fast and dilutes into nothing when added to slow queries that have taken at least 500ms, even more than in CNDB-15260 given that the reports are much smaller than with SAI queries. Regarding the cost of tracking the number of fetched/returned/deleted partitions and rows, which happens on every query even if it's not slow, it seems to get lost in the benchmark error and I cannot see a noticeable impact. |
…ands Enabled by default, can be disabled with property cassandra.monitoring_execution_info_enabled
It is always accessed by the same ReadStage tread, which puts it in the BlockingQueue consumed by the monitoring thread
3253559 to
8b59023
Compare
|
❌ Build ds-cassandra-pr-gate/PR-2147 rejected by Butler2 regressions found Found 2 new test failures
Found 2 known test failures |
|
Thanks for the review :) |



What is the issue
CNDB-15260 added SAI-specific information to the log reports produced for slow queries. This execution information contains, among others, the number of fetched and returned partitions, rows and tombstones. However, the logging reports for non-SAI slow queries don't have a similar information about the number of filtered rows, tombstones, etc.
What does this PR fix and why was it fixed
This PR adds information about fetched/returned partitions/rows/tombstones to the logging reports for non-SAI slow queries. The reports look like:
Whereas without this feature it would miss the three last lines:
The format of the log messages tries to save disk space while keeping some readability.
There is a system property named
cassandra.monitoring_execution_info_enabledto disable this feature, which is enabled by default.