Skip to content
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

Receiver: Use intern package when reallocating label strings #5926

Merged
merged 9 commits into from
Feb 1, 2023

Conversation

matej-g
Copy link
Collaborator

@matej-g matej-g commented Nov 29, 2022

  • I added CHANGELOG entry for this change.
  • Change is not relevant to the end user.

Changes

This is an alternative to #5899 (please see that PR for rational for this change) but uses the go4org/intern instead of our homebrewed method. The advantage of this is that the go4org/intern package is capable of dropping references to unused string automatically, so we don't have to worry about cleaning up references manually (by e.g. counting usage, dropping references periodically etc.) or worry about keeping stale references, causing a memory build-up over longer time.

The downside is that the package violates safe practices when it comes to operating with pointers. However, the package takes precautions to prevent problems with the program (for full details see: https://mdlayher.com/blog/unsafe-string-interning-in-go/). Moreover, the package is written and maintained by some of the developers that are close to the upstream Go community, who ensure the quality of the code is up to Go's standards. The package is considered mature and stable as per project's description. Considering all of this, I believe it is safe to use the package in Thanos as well.

If people deem this still too risky we can consider our own safe implementation via #5899.

Verification

We (cc @philipgough )have run this in a synthetic load test with k6 load testing tools on a cluster of 6 receivers with replication factor 3. Overall, we could confirm some gains with this change. We clearly keep fewer objects in heap as expected (average by pod for each respective version, graph on the right). On the actual heap size and working set metrics, we could confirm improvement of at least 1-2 GB average per receiver replica (values are in GB, green is latest main, yellow ismain + PR changes):

image

On local benchmark levels, both label and handler benchmarks seem to remain on tolerable levels (with the exception of extremely large label number i.e. from 100000). This is expected as the gain should come from keeping fewer objects in memory for long term rather then fewer allocations.

name                                                                           old time/op    new time/op    delta
TransformWithAndWithoutCopyWithSingleLabel/ZLabelsToPromLabels-12                1.50ns ± 2%    1.53ns ± 6%      ~     (p=0.841 n=5+5)
TransformWithAndWithoutCopyWithSingleLabel/ZLabelsToPromLabelsWithRealloc-12     50.4ns ± 3%   133.2ns ± 2%  +164.21%  (p=0.008 n=5+5)
TransformWithAndWithoutCopyWith1000Labels/ZLabelsToPromLabels-12                 1.57ns ± 4%    1.52ns ± 2%      ~     (p=0.056 n=5+5)
TransformWithAndWithoutCopyWith1000Labels/ZLabelsToPromLabelsWithRealloc-12      48.5µs ± 3%   161.1µs ± 1%  +232.22%  (p=0.008 n=5+5)
TransformWithAndWithoutCopyWith100000Labels/ZLabelsToPromLabels-12               1.51ns ± 0%    1.51ns ± 1%      ~     (p=0.286 n=4+5)
TransformWithAndWithoutCopyWith100000Labels/ZLabelsToPromLabelsWithRealloc-12    5.44ms ± 3%   34.98ms ±10%  +542.99%  (p=0.008 n=5+5)

name                                                                           old alloc/op   new alloc/op   delta
TransformWithAndWithoutCopyWithSingleLabel/ZLabelsToPromLabels-12                 0.00B          0.00B           ~     (all equal)
TransformWithAndWithoutCopyWithSingleLabel/ZLabelsToPromLabelsWithRealloc-12      96.0B ± 0%     96.0B ± 0%      ~     (all equal)
TransformWithAndWithoutCopyWith1000Labels/ZLabelsToPromLabels-12                  0.00B          0.00B           ~     (all equal)
TransformWithAndWithoutCopyWith1000Labels/ZLabelsToPromLabelsWithRealloc-12      96.0kB ± 0%    96.0kB ± 0%    +0.00%  (p=0.008 n=5+5)
TransformWithAndWithoutCopyWith100000Labels/ZLabelsToPromLabels-12                0.00B          0.00B           ~     (all equal)
TransformWithAndWithoutCopyWith100000Labels/ZLabelsToPromLabelsWithRealloc-12    9.60MB ± 0%    9.67MB ± 1%    +0.69%  (p=0.008 n=5+5)

name                                                                           old allocs/op  new allocs/op  delta
TransformWithAndWithoutCopyWithSingleLabel/ZLabelsToPromLabels-12                  0.00           0.00           ~     (all equal)
TransformWithAndWithoutCopyWithSingleLabel/ZLabelsToPromLabelsWithRealloc-12       2.00 ± 0%      2.00 ± 0%      ~     (all equal)
TransformWithAndWithoutCopyWith1000Labels/ZLabelsToPromLabels-12                   0.00           0.00           ~     (all equal)
TransformWithAndWithoutCopyWith1000Labels/ZLabelsToPromLabelsWithRealloc-12       2.00k ± 0%     2.00k ± 0%      ~     (all equal)
TransformWithAndWithoutCopyWith100000Labels/ZLabelsToPromLabels-12                 0.00           0.00           ~     (all equal)
TransformWithAndWithoutCopyWith100000Labels/ZLabelsToPromLabelsWithRealloc-12      200k ± 0%      203k ± 2%    +1.65%  (p=0.008 n=5+5)
name                                                                                old time/op    new time/op    delta
HandlerReceiveHTTP/typical_labels_under_1KB,_500_of_them/OK-12                         939µs ± 6%     944µs ± 7%     ~     (p=0.548 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_500_of_them/conflict_errors-12           1.12ms ± 6%    1.12ms ± 4%     ~     (p=1.000 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_5000_of_them/OK-12                       9.43ms ± 5%   10.64ms ± 8%  +12.90%  (p=0.008 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_5000_of_them/conflict_errors-12          11.1ms ± 7%    11.9ms ± 9%     ~     (p=0.056 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_20000_of_them/OK-12                      38.0ms ± 5%    38.9ms ± 2%     ~     (p=0.310 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_20000_of_them/conflict_errors-12         44.5ms ± 2%    45.7ms ± 5%     ~     (p=0.548 n=5+5)
HandlerReceiveHTTP/extremely_large_label_value_10MB,_10_of_them/OK-12                 85.0ms ±16%    86.2ms ± 1%     ~     (p=0.151 n=5+5)
HandlerReceiveHTTP/extremely_large_label_value_10MB,_10_of_them/conflict_errors-12    84.1ms ± 8%    85.6ms ± 1%     ~     (p=0.310 n=5+5)

name                                                                                old alloc/op   new alloc/op   delta
HandlerReceiveHTTP/typical_labels_under_1KB,_500_of_them/OK-12                        1.15MB ± 0%    1.15MB ± 0%     ~     (p=0.222 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_500_of_them/conflict_errors-12           1.41MB ± 0%    1.41MB ± 0%     ~     (p=0.056 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_5000_of_them/OK-12                       13.1MB ± 0%    13.1MB ± 0%     ~     (p=0.310 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_5000_of_them/conflict_errors-12          15.5MB ± 0%    15.5MB ± 0%     ~     (p=0.056 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_20000_of_them/OK-12                      53.0MB ± 0%    53.0MB ± 1%     ~     (p=0.413 n=4+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_20000_of_them/conflict_errors-12         62.0MB ± 0%    62.0MB ± 0%     ~     (p=1.000 n=5+5)
HandlerReceiveHTTP/extremely_large_label_value_10MB,_10_of_them/OK-12                  110MB ± 0%     110MB ± 0%     ~     (p=0.730 n=4+5)
HandlerReceiveHTTP/extremely_large_label_value_10MB,_10_of_them/conflict_errors-12     110MB ± 0%     110MB ± 0%     ~     (p=1.000 n=5+5)

name                                                                                old allocs/op  new allocs/op  delta
HandlerReceiveHTTP/typical_labels_under_1KB,_500_of_them/OK-12                         3.10k ± 0%     3.10k ± 0%     ~     (all equal)
HandlerReceiveHTTP/typical_labels_under_1KB,_500_of_them/conflict_errors-12            6.63k ± 0%     6.63k ± 0%     ~     (p=0.333 n=4+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_5000_of_them/OK-12                        30.3k ± 0%     30.3k ± 0%     ~     (p=0.571 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_5000_of_them/conflict_errors-12           65.1k ± 0%     65.2k ± 0%     ~     (p=0.444 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_20000_of_them/OK-12                        121k ± 0%      121k ± 0%     ~     (p=0.738 n=5+5)
HandlerReceiveHTTP/typical_labels_under_1KB,_20000_of_them/conflict_errors-12           260k ± 0%      260k ± 0%     ~     (p=1.000 n=5+5)
HandlerReceiveHTTP/extremely_large_label_value_10MB,_10_of_them/OK-12                   89.6 ± 4%      88.8 ± 1%     ~     (p=0.667 n=5+5)
HandlerReceiveHTTP/extremely_large_label_value_10MB,_10_of_them/conflict_errors-12       220 ± 1%       220 ± 1%     ~     (p=1.000 n=5+5)

Signed-off-by: Matej Gera <matejgera@gmail.com>
Signed-off-by: Matej Gera <matejgera@gmail.com>
Signed-off-by: Matej Gera <matejgera@gmail.com>
@fpetkovski
Copy link
Contributor

This looks quite cool and also simpler than the first implementation. It's interesting that benchmarks show no real difference :)

@douglascamata
Copy link
Contributor

douglascamata commented Nov 29, 2022

This is awesome, @matej-g! 😮 🙇 🚀

@fpetkovski the benchmarking code manually calls the GC in between calls to the benchmarked function. I suspect this triggers a cleanup of the interned strings as their only refs go away.

@matej-g
Copy link
Collaborator Author

matej-g commented Nov 29, 2022

@fpetkovski @douglascamata Honestly I'm not sure, this is one thing I still did not manage to figure fully out. My assumption is that we're still allocating each label string but eventually we're keeping one copy of the string around for long time and garbage collecting the others.

@douglascamata
Copy link
Contributor

@matej-g your statement seems correct to me. We keep a single copy of the interned strings. But the actual strings aren't kept forever in memory forever and will be garbage collected if they have no more references (see https://github.com/go4org/intern/blob/main/intern.go#L141). So the GC run in between benchmark iterations is likely cleaning things up.

You could confirm it by running the code being benchmarked twice for each benchmark iteration. Comparing to running twice without interning, we should be able to see the memory difference.

@saswatamcode
Copy link
Member

This looks really cool! 🌟

For the benchmarks, I don't think we manually call GC in the benchmark, but only manually call it after all the benchmark test cases here. But you'd have auto GC cycles running during benchmark anyway!

You can try running the benchmark with GODEBUG=gctrace=1 and see when the GC is working and try to set GC pacing with GOGC. I think there is some nuance to it being (forced) as well. 🙂

@douglascamata
Copy link
Contributor

douglascamata commented Nov 30, 2022

@saswatamcode internal code in the benchmark package is calling the GC, not our code: https://github.com/golang/go/blob/master/src/testing/benchmark.go#L187

@stale
Copy link

stale bot commented Jan 7, 2023

Hello 👋 Looks like there was no activity on this amazing PR for the last 30 days.
Do you mind updating us on the status? Is there anything we can help with? If you plan to still work on it, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity in the next week, this issue will be closed (we can always reopen a PR if you get back to this!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Jan 7, 2023
GiedriusS
GiedriusS previously approved these changes Jan 24, 2023
Copy link
Member

@GiedriusS GiedriusS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 I took a deeper look and would like to try getting this in. Perhaps this could be behind a feature flag in Thanos Receive?

@matej-g
Copy link
Collaborator Author

matej-g commented Jan 24, 2023

@GiedriusS I'm fine with that, sorry for the delays and leaving this unfinished, if this looks good I can sanitise this PR and un-draft it

@stale stale bot removed the stale label Jan 24, 2023
@GiedriusS
Copy link
Member

Yeah, I think let's put this under a feature flag and merge this so others could try it out as well. Thanks for your work 🙇

Signed-off-by: Matej Gera <matej.gera@coralogix.com>
Signed-off-by: Matej Gera <matej.gera@coralogix.com>
Signed-off-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
@matej-g matej-g marked this pull request as ready for review January 31, 2023 10:21
@matej-g
Copy link
Collaborator Author

matej-g commented Jan 31, 2023

Looks like l forgot to undraft, this should now be ready for final approvals, thanks cc @GiedriusS @douglascamata @saswatamcode

douglascamata
douglascamata previously approved these changes Jan 31, 2023
Copy link
Contributor

@douglascamata douglascamata left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks a lot, @matej-g 🙇

Can't wait to try this one out.

philipgough
philipgough previously approved these changes Jan 31, 2023
Copy link
Contributor

@philipgough philipgough left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

- Fix wrong condition
- Adjust benchmarks

Signed-off-by: Matej Gera <matej.gera@coralogix.com>
@pull-request-size pull-request-size bot added size/L and removed size/M labels Feb 1, 2023
@matej-g matej-g requested review from GiedriusS, douglascamata and philipgough and removed request for douglascamata and philipgough February 1, 2023 08:18
Copy link
Member

@GiedriusS GiedriusS left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎖️

@GiedriusS GiedriusS merged commit dbacf40 into thanos-io:main Feb 1, 2023
rabenhorst added a commit to rabenhorst/thanos that referenced this pull request Feb 8, 2023
* Update Thanos engine to latest version (thanos-io#6069)

This commit updates the Thanos PromQL engine to the latest version.

Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>

Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>

* Receive: Tenants' external labels proposal (thanos-io#5720)

* Receive external labels proposal

Signed-off-by: haanhvu <haanh6594@gmail.com>

* Restructure and edit proposal's content

Signed-off-by: haanhvu <haanh6594@gmail.com>

* Update proposal

Signed-off-by: haanhvu <haanh6594@gmail.com>

* Fix doc error

Signed-off-by: haanhvu <haanh6594@gmail.com>

Signed-off-by: haanhvu <haanh6594@gmail.com>

* fixing doc CI (thanos-io#6072)

Signed-off-by: Ben Ye <benye@amazon.com>

Signed-off-by: Ben Ye <benye@amazon.com>

* Fix stores filtering resets on reload (thanos-io#6063)

* Fix stores filtering resets on reload

`g0.store_matches` parameter appears in the url but doesn't applies
in the frontend. Looks like it has been done on purpose and by
removing a small piece of code fixes this issue.

variable named `debugMode` is used for the store filtering checkbox
which is an unappropriate name. Using `enableStoreFiltering`
variable to represent the state of checkbox.

Signed-off-by: Pradyumna Krishna <git@onpy.in>

* Regenerate bindata.go

Signed-off-by: Pradyumna Krishna <git@onpy.in>

Signed-off-by: Pradyumna Krishna <git@onpy.in>

* Store: Make initial sync more robust

Added re-try mechanism for store inital sync, where if the initial sync fails, it tries to do the initial sync again for given timeout duration.

Signed-off-by: Kartik-Garg <kartik.garg@infracloud.io>

* Recover from panics in Series calls (thanos-io#6077)

* Recover from panics in Series calls

This commit adds panic recovery for Series calls in all Store servers.

Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>

* Apply error suggestion

Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>

---------

Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>

* query: reuse our own gate (thanos-io#6079)

Do not call promgate directly but rather use our own wrapper that does
everything we want - duration histogram, current in-flight calls, total
calls.

Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>

* Store: Support disable cache index header file. (thanos-io#5773)

* Store: Support disable cache index header file.

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* Store: add a seprate flag to disable caching index header file

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* Tools: add cleanup API for bucket web

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* resolve conversation

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* resolve confilcts

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* change the flag to `--cache-index-header`

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* Wrap mem writer in file writer

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* update CHANGELOG

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* update CHANGELOG

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

* fix bug

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>

---------

Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>
Co-authored-by: wanjunlei <wanjunlei@yujnify.com>

* CVE: Fix Receiver malicious tenant (thanos-io#5969)

If running as root or with enough privileges, receiver can create a
directory outside of the configured TenantHeader.

This commit fixes it up by sanitizing the user input and explicity not
allowing such behavior.

Signed-off-by: Daniel Mellado <dmellado@redhat.com>

* Add adopter Grupo MasMovil (thanos-io#6084)

Signed-off-by: Pablo Moncada Isla <pablo.moncada@masmovil.com>

* fix typo (thanos-io#6087)

Signed-off-by: cyip <cyip@jackhenry.com>
Co-authored-by: cyip <cyip@jackhenry.com>

* optimize selector to string (thanos-io#6076)

Signed-off-by: Kama Huang <kamatogo13@gmail.com>

* Fix: Failure to close BlockSeriesClient cause store-gateway deadlock (thanos-io#6086)

* Fix: Failure to close BlockSeriesClient cause store-gateway deadlock

Signed-off-by: Alan Protasio <alanprot@gmail.com>

* Adding tests

Signed-off-by: Alan Protasio <alanprot@gmail.com>

* reverting the change on get series

Signed-off-by: Alan Protasio <alanprot@gmail.com>

* fix lint

Signed-off-by: Alan Protasio <alanprot@gmail.com>

---------

Signed-off-by: Alan Protasio <alanprot@gmail.com>

* Cut 0.30.2 (thanos-io#6081)

* tracing: fixed panic because of nil sampler (thanos-io#6066)

* fixed panic because of nil sampler

Signed-off-by: Vasiliy Rumyantsev <4119114+xBazilio@users.noreply.github.com>

* added CHANGELOG entry

Signed-off-by: Vasiliy Rumyantsev <4119114+xBazilio@users.noreply.github.com>

Signed-off-by: Vasiliy Rumyantsev <4119114+xBazilio@users.noreply.github.com>

* bump version to 0.30.2

Signed-off-by: Ben Ye <benye@amazon.com>

* Updates busybox SHA (thanos-io#6046)

Signed-off-by: GitHub <noreply@github.com>

Signed-off-by: GitHub <noreply@github.com>
Co-authored-by: yeya24 <yeya24@users.noreply.github.com>

* Use `e2edb.NewMinio` to disable SSE-S3 in e2e tests (thanos-io#6055)

* Use e2edb.NewMinio to disable SSE

Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>

* Use temp fork for TLS

Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>

* Fix broken rules api fanout test

Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>

* Fix broken query compatibility test

Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>

* Remove fork

Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>

Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>

---------

Signed-off-by: Vasiliy Rumyantsev <4119114+xBazilio@users.noreply.github.com>
Signed-off-by: Ben Ye <benye@amazon.com>
Signed-off-by: GitHub <noreply@github.com>
Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Co-authored-by: Vasiliy Rumyantsev <4119114+xBazilio@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: yeya24 <yeya24@users.noreply.github.com>
Co-authored-by: Saswata Mukherjee <saswataminsta@yahoo.com>

* cherry pick store gateway fix to release 0.30 (thanos-io#6089)

* Fix: Failure to close BlockSeriesClient cause store-gateway deadlock (thanos-io#6086)

* Fix: Failure to close BlockSeriesClient cause store-gateway deadlock

Signed-off-by: Alan Protasio <alanprot@gmail.com>

* Adding tests

Signed-off-by: Alan Protasio <alanprot@gmail.com>

* reverting the change on get series

Signed-off-by: Alan Protasio <alanprot@gmail.com>

* fix lint

Signed-off-by: Alan Protasio <alanprot@gmail.com>

---------

Signed-off-by: Alan Protasio <alanprot@gmail.com>

* update changelog

Signed-off-by: Ben Ye <benye@amazon.com>

---------

Signed-off-by: Alan Protasio <alanprot@gmail.com>
Signed-off-by: Ben Ye <benye@amazon.com>
Co-authored-by: Alan Protasio <alanprot@gmail.com>

* fix changelog entries

Signed-off-by: Ben Ye <benye@amazon.com>

* docs: improving the description for tsdb.retention on the receiver

Signed-off-by: Victor Fernandes <victorhbfernandes@gmail.com>

* Receiver: Use `intern` package when reallocating label strings (thanos-io#5926)

* Cleanup go mod

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Use string interning for labels realloc method

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Enhance label realloc benchmarks

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Make interning optional; put behind hiddend flag

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

* Update CHANGELOG

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

* Address feedback

- Fix wrong condition
- Adjust benchmarks

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

---------

Signed-off-by: Matej Gera <matejgera@gmail.com>
Signed-off-by: Matej Gera <matej.gera@coralogix.com>
Signed-off-by: Matej Gera <38492574+matej-g@users.noreply.github.com>

* Updaing README with drawing fixes and minor wording clarification (thanos-io#6078)

* New drawing and wording for Thanos other deployment models

Signed-off-by: Jonah Kowall <jkowall@kowall.net>

* New drawing and wording for Thanos other deployment models

Signed-off-by: Jonah Kowall <jkowall@kowall.net>

* Added comments to README.md and updated the quick-tutorial.md with the same diagram updates and text to match

Signed-off-by: Jonah Kowall <jkowall@kowall.net>

* Ran make docs

Signed-off-by: Jonah Kowall <jkowall@kowall.net>

---------

Signed-off-by: Jonah Kowall <jkowall@kowall.net>

* Compact: Remove spam of replica label removed log (thanos-io#6088)

* Remove spam of replica label removed log

Signed-off-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>

* Reduce amount of removed replica label instead of removing it

Signed-off-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>

* Reformat code

Signed-off-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>

---------

Signed-off-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>

* Store: Don't error when no stores are matched (thanos-io#6082)

It's normal and not an error if a query does not match due to no
downstream stores. This is common when querying with external labels and
tiered query servers.

This bug was introduced in thanos-io#5296

Fixes: thanos-io#5862

Signed-off-by: SuperQ <superq@gmail.com>

* docs: Fix must have Ruler alerts definition (thanos-io#6058)

* Fix must have Ruler alerts definition

ThanosRuler missing rule intervals metric used the wrong comparator sign, confusing users trying to create the rule.



Signed-off-by: Maxim Muzafarov <m.muzafarov@gmail.com>

* Update docs/components/rule.md

Co-authored-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Signed-off-by: Maxim Muzafarov <m.muzafarov@gmail.com>

---------

Signed-off-by: Maxim Muzafarov <m.muzafarov@gmail.com>
Co-authored-by: Saswata Mukherjee <saswataminsta@yahoo.com>

* Fix conflicts

Signed-off-by: haanhvu <haanh6594@gmail.com>

* Specify overwriting behavior in flag and add validation

Signed-off-by: haanhvu <haanh6594@gmail.com>

* Add log and doc

Signed-off-by: haanhvu <haanh6594@gmail.com>

* Mixins(Rule): Fix query for long rule evaluations (thanos-io#6103)

* mixin(Rule): Fix query for long rule evaluations

Signed-off-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>

* Update changelog

Signed-off-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>

---------

Signed-off-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>

---------

Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>
Signed-off-by: haanhvu <haanh6594@gmail.com>
Signed-off-by: Ben Ye <benye@amazon.com>
Signed-off-by: Pradyumna Krishna <git@onpy.in>
Signed-off-by: Kartik-Garg <kartik.garg@infracloud.io>
Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
Signed-off-by: wanjunlei <wanjunlei@kubesphere.io>
Signed-off-by: Daniel Mellado <dmellado@redhat.com>
Signed-off-by: Pablo Moncada Isla <pablo.moncada@masmovil.com>
Signed-off-by: cyip <cyip@jackhenry.com>
Signed-off-by: Kama Huang <kamatogo13@gmail.com>
Signed-off-by: Alan Protasio <alanprot@gmail.com>
Signed-off-by: Vasiliy Rumyantsev <4119114+xBazilio@users.noreply.github.com>
Signed-off-by: GitHub <noreply@github.com>
Signed-off-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Signed-off-by: Victor Fernandes <victorhbfernandes@gmail.com>
Signed-off-by: Matej Gera <matejgera@gmail.com>
Signed-off-by: Matej Gera <matej.gera@coralogix.com>
Signed-off-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
Signed-off-by: Jonah Kowall <jkowall@kowall.net>
Signed-off-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>
Signed-off-by: SuperQ <superq@gmail.com>
Signed-off-by: Maxim Muzafarov <m.muzafarov@gmail.com>
Signed-off-by: Sebastian Rabenhorst <sebastian.rabenhorst@shopify.com>
Co-authored-by: Filip Petkovski <filip.petkovsky@gmail.com>
Co-authored-by: Ha Anh Vu <75315486+haanhvu@users.noreply.github.com>
Co-authored-by: Ben Ye <benye@amazon.com>
Co-authored-by: Pradyumna Krishna <git@onpy.in>
Co-authored-by: Kartik-Garg <kartik.garg@infracloud.io>
Co-authored-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
Co-authored-by: wanjunlei <53003665+wanjunlei@users.noreply.github.com>
Co-authored-by: wanjunlei <wanjunlei@yujnify.com>
Co-authored-by: Daniel Mellado <1313475+danielmellado@users.noreply.github.com>
Co-authored-by: Pablo Moncada <pmoncadaisla@gmail.com>
Co-authored-by: Chantel Yip <52993239+sshantel@users.noreply.github.com>
Co-authored-by: cyip <cyip@jackhenry.com>
Co-authored-by: Kama Huang <121007071+kama910@users.noreply.github.com>
Co-authored-by: Alan Protasio <alanprot@gmail.com>
Co-authored-by: Vasiliy Rumyantsev <4119114+xBazilio@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: yeya24 <yeya24@users.noreply.github.com>
Co-authored-by: Saswata Mukherjee <saswataminsta@yahoo.com>
Co-authored-by: Victor Fernandes <victorhbfernandes@gmail.com>
Co-authored-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
Co-authored-by: Jonah Kowall <jkowall@kowall.net>
Co-authored-by: Douglas Camata <159076+douglascamata@users.noreply.github.com>
Co-authored-by: Ben Kochie <superq@gmail.com>
Co-authored-by: Maxim Muzafarov <m.muzafarov@gmail.com>
Co-authored-by: haanhvu <haanh6594@gmail.com>
ngraham20 pushed a commit to ngraham20/thanos that referenced this pull request Apr 17, 2023
…s-io#5926)

* Cleanup go mod

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Use string interning for labels realloc method

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Enhance label realloc benchmarks

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Make interning optional; put behind hiddend flag

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

* Update CHANGELOG

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

* Address feedback

- Fix wrong condition
- Adjust benchmarks

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

---------

Signed-off-by: Matej Gera <matejgera@gmail.com>
Signed-off-by: Matej Gera <matej.gera@coralogix.com>
Signed-off-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
ngraham20 pushed a commit to ngraham20/thanos that referenced this pull request Apr 17, 2023
…s-io#5926)

* Cleanup go mod

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Use string interning for labels realloc method

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Enhance label realloc benchmarks

Signed-off-by: Matej Gera <matejgera@gmail.com>

* Make interning optional; put behind hiddend flag

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

* Update CHANGELOG

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

* Address feedback

- Fix wrong condition
- Adjust benchmarks

Signed-off-by: Matej Gera <matej.gera@coralogix.com>

---------

Signed-off-by: Matej Gera <matejgera@gmail.com>
Signed-off-by: Matej Gera <matej.gera@coralogix.com>
Signed-off-by: Matej Gera <38492574+matej-g@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants