-
Notifications
You must be signed in to change notification settings - Fork 512
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 segmentation fault in Ingester.LabelValues response marshaling #8003
Conversation
Did you conclude against a custom gRPC codec, then? |
Yeah, if it is unlikely to degrade things, then the decreased fiddly-ness and complexity of this fix seems preferable to me. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, except the changelog entry needs to point to the PR.
Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
What this PR does
This PR fixes a segmentation fault (see #7897) that happens when ongoing compaction in the ingester unmaps an index file that an in-flight
Ingester.LabelValues
response hasn't yet marshaled.I am doing the simplest thing here which is to make a copy of all of the label value strings.
I did some analysis on the
Ingester.LabelValues
usage we see. Some ingester pods do see ~200 RPS of LabelValues invocations. The vast majority of calls are in the smaller response sizes. But, we do some some regular periodic LabelValues calls where the response is >25mb. (And sometimes >250mb.) These larger ones are just a few times per minute when they do happen, so I suspect it won't be problematic. But I welcome additional points of view.Which issue(s) this PR fixes or relates to
Fixes #7897
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]
.about-versioning.md
updated with experimental features.