receive: memoize exemplar/TSDB clients#7782
Merged
Conversation
46df56c to
8436179
Compare
We call this on each Series() so memoize the creation of this slice. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
8436179 to
4024931
Compare
niaurys
approved these changes
Sep 25, 2024
jnyi
pushed a commit
to jnyi/thanos
that referenced
this pull request
Oct 17, 2024
We call this on each Series() so memoize the creation of this slice. Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
This was referenced Oct 23, 2024
Contributor
|
this pr introduced a bug when multiple tenants are created at the same time, only partial tenants would be memorized due to atomicity issue with the bool flag and where the slice gets updated, fyi @GiedriusS we plan to revert this pr internally but worth taking a look, it prevents new tenants to be queriable but luckily no data loss after restart the server |
2 tasks
hczhu-db
reviewed
Nov 23, 2024
Comment on lines
+615
to
+618
| if !t.tsdbClientsNeedUpdate { | ||
| return t.tsdbClients | ||
| } | ||
| defer t.mtx.Unlock() |
Contributor
There was a problem hiding this comment.
defer t.mtx.Unlock() should be before if. @jnyi
Member
Author
There was a problem hiding this comment.
Thanks; care opening up a PR with the fix?
Contributor
There was a problem hiding this comment.
no, we found a different bug, I submit a PR to fix it, please take a look when you have time: #7941
2 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We call this on each Series() so memoize the creation of this slice.