-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
feat(blooms): ignore individual bloom-gw failures #12863
Conversation
owen-d
commented
May 2, 2024
- includes a new metric to record statuses now that we ignore errors
- Also removes old/no longer relevant cache locality score metric since we now resolve bloom-gw membership in a different way
Signed-off-by: Owen Diehl <[email protected]>
pkg/bloomgateway/client.go
Outdated
"blocks", len(rs.blocks), | ||
"err", err, | ||
) | ||
return nil |
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.
In case a request fails, the results entries need to be equal to the request entries, otherwise we assume that all requested chunks have been filtered out.
return nil | |
results[i] = rs.groups | |
count += len(rs.groups) | |
return nil |
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.
Increasing count
is not strictly needed, but the value is used for the allocation of the result buffer.
Buckets: prometheus.LinearBuckets(0.01, 0.2, 5), | ||
}), | ||
Name: "requests_total", | ||
Help: "Total number of requests made to the bloom gateway", |
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.
👍
Signed-off-by: Owen Diehl <[email protected]>
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.
Minor nitpicks, but approved to unblock
pkg/bloomgateway/client.go
Outdated
"blocks", len(rs.blocks), | ||
"err", err, | ||
) | ||
return nil |
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.
Increasing count
is not strictly needed, but the value is used for the allocation of the result buffer.
pkg/bloomgateway/client_test.go
Outdated
@@ -52,7 +52,7 @@ func TestGatewayClient_MergeSeries(t *testing.T) { | |||
{Fingerprint: 0x01, Refs: []*logproto.ShortRef{shortRef(0, 1, 3), shortRef(1, 2, 4)}}, // fully overlapping chunks | |||
{Fingerprint: 0x02, Refs: []*logproto.ShortRef{shortRef(0, 1, 5), shortRef(1, 2, 6)}}, // partially overlapping chunks | |||
}, | |||
// response 2 | |||
// response 3 |
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
…in all cases Signed-off-by: Owen Diehl <[email protected]>
Signed-off-by: Owen Diehl <[email protected]>
(cherry picked from commit 4c9b22f)
Backport 4c9b22f from #12863 Co-authored-by: Owen Diehl <[email protected]>