-
Notifications
You must be signed in to change notification settings - Fork 634
MQE: include additional information when panicking because estimated memory consumption is negative #11615
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
…memory consumption is negative
7bf0da0
to
fbcf221
Compare
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new branch
git switch --create backport-11615-to-r345 origin/r345
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x 8139c71bb0ee9b8c66aea781b6c4cf0c37c4e01b
# Push it to GitHub
git push --set-upstream origin backport-11615-to-r345
git switch main
# Remove the local backport branch
git branch -D backport-11615-to-r345 Then, create a pull request where the |
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new branch
git switch --create backport-11615-to-r341 origin/r341
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x 8139c71bb0ee9b8c66aea781b6c4cf0c37c4e01b
# Push it to GitHub
git push --set-upstream origin backport-11615-to-r341
git switch main
# Remove the local backport branch
git branch -D backport-11615-to-r341 Then, create a pull request where the |
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new branch
git switch --create backport-11615-to-r343 origin/r343
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x 8139c71bb0ee9b8c66aea781b6c4cf0c37c4e01b
# Push it to GitHub
git push --set-upstream origin backport-11615-to-r343
git switch main
# Remove the local backport branch
git branch -D backport-11615-to-r343 Then, create a pull request where the |
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new branch
git switch --create backport-11615-to-r344 origin/r344
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x 8139c71bb0ee9b8c66aea781b6c4cf0c37c4e01b
# Push it to GitHub
git push --set-upstream origin backport-11615-to-r344
git switch main
# Remove the local backport branch
git branch -D backport-11615-to-r344 Then, create a pull request where the |
… becomes negative (#11713) #### What this PR does This PR adds the trace ID (if any) to the panic message used if the estimated memory consumption of a query becomes negative. #### Which issue(s) this PR fixes or relates to #11615, #11654 #### Checklist - [x] Tests updated. - [n/a] Documentation added. - [covered by #10067] `CHANGELOG.md` updated - the order of entries should be `[CHANGE]`, `[FEATURE]`, `[ENHANCEMENT]`, `[BUGFIX]`. - [n/a] [`about-versioning.md`](https://github.com/grafana/mimir/blob/main/docs/sources/mimir/configure/about-versioning.md) updated with experimental features.
What this PR does
MQE panics when the estimated memory consumption of a query goes negative, as this indicates that something was returned to a pool multiple times, which could lead to incorrect query results.
However, when this happens in a production environment, it can be quite difficult to debug this, as it's often difficult to determine which query was affected: the panic often happens when
Query.Close()
is called, which is not tracked by the activity tracker, and so the query doesn't appear in the list of inflight queries when the querier restarts.So, in this PR, I'm adding the query expression to the panic message to make it a bit easier to figure out what happened.
Which issue(s) this PR fixes or relates to
#10067
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]
.about-versioning.md
updated with experimental features.