Skip to content

Conversation

@michaelsembwever
Copy link
Member

https://github.com/riptano/cndb/issues/16026

Port into main-5.0 commit ea6d75e

CNDB-16026: CNDB-15971: Only init ReadExecutionController's histogram when tracing on when tracing on (#2118)

Fixes: https://github.com/riptano/cndb/issues/15971
CNDB PR: https://github.com/riptano/cndb/pull/15986

In #800, we added a histogram to the `ReadExecutionController` to track some metric, but it is only observed when tracing is enabled. I propose that instead of creating one and tracking for every query, we only do that when tracing is enabled.

Perhaps we could remove the logic entirely, but this solution will likely take care of all performance concerns related to unnecessary allocations and unnecessary tracking when updating the histogram.

### What is the issue
...

### What does this PR fix and why was it fixed
...

… when tracing on (#2118)

Fixes: riptano/cndb#15971
CNDB PR: riptano/cndb#15986

In #800, we added a histogram to the `ReadExecutionController` to track
some metric, but it is only observed when tracing is enabled. I propose
that instead of creating one and tracking for every query, we only do
that when tracing is enabled.

Perhaps we could remove the logic entirely, but this solution will
likely take care of all performance concerns related to unnecessary
allocations and unnecessary tracking when updating the histogram.
@github-actions
Copy link

Checklist before you submit for review

  • This PR adheres to the Definition of Done
  • Make sure there is a PR in the CNDB project updating the Converged Cassandra version
  • Use NoSpamLogger for log lines that may appear frequently in the logs
  • Verify test results on Butler
  • Test coverage for new/modified code is > 80%
  • Proper code formatting
  • Proper title for each commit staring with the project-issue number, like CNDB-1234
  • Each commit has a meaningful description
  • Each commit is not very long and contains related changes
  • Renames, moves and reformatting are in distinct commits
  • All new files should contain the DataStax copyright header instead of the Apache License one

@sonarqubecloud
Copy link

@cassci-bot
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants