-
Notifications
You must be signed in to change notification settings - Fork 634
Mimir query engine: annotations #8660
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
…perator factories
…formation in annotations
b960936
to
da1c812
Compare
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.
Just curious if we need to handle info annotations, or if only warnings come through the query engine?
for engineName, engine := range engines { | ||
t.Run(engineName, func(t *testing.T) { | ||
for queryType, generator := range queryTypes { | ||
t.Run(queryType, func(t *testing.T) { |
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.
(nit) We seem to be setting up these multi-engine, multi-query type comparison tests in a few places. I wonder if we can make some helpers?
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.
It's a good idea - I'll have a think and maybe try to pull this out as a separate PR.
Both are handled as annotations in the same way, but both are emitted together in one (confusingly named) The only difference between warnings and info annotations are the message: warnings start with |
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, but if possible would love to move this behind #8577
# Conflicts: # CHANGELOG.md # tools/querytee/response_comparator.go # tools/querytee/response_comparator_test.go
I've merged in the latest changes from |
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
# Conflicts: # CHANGELOG.md # pkg/streamingpromql/operators/aggregation.go # pkg/streamingpromql/operators/function_over_range_vector.go
Putting this back to a draft - this needs to be reworked slightly for the annotation emitted by |
… samples are present
This is ready to go again. |
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 fine, but I'm not a huge fan of the haveFloats
. I'm not sure that'll make sense when we make the functions generic in #8747.
If possible, can we resolve (as in come to agreement on) the open discussions on there and then decide which one we merge first and which one we re-work?
8fcabb2
to
8b3b88f
Compare
# Conflicts: # CHANGELOG.md # pkg/streamingpromql/functions.go # pkg/streamingpromql/operators/function_over_range_vector.go # tools/querytee/response_comparator_test.go
What this PR does
This PR adds support for annotations (aka warnings) to the Mimir query engine.
It adds support for a single annotation that Prometheus' engine emits:
sum()
with both float and histogram samples at the same timestep for the same output series(This PR previously also included adding an annotation for
rate()
over a suspected non-counter, but that will be added in a separate PR.)The latency impact of these changes is low (<1% for our benchmarks), and the impact on peak memory utilisation is within the margin of error for our benchmarks.
This PR also adds support for comparing warnings when comparing results in query-tee.
Which issue(s) this PR fixes or relates to
(none)
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]
.about-versioning.md
updated with experimental features.