prometheus/storage/remote
Robert Fratto a09465baee
storage/remote: disable resharding during active retry backoffs (#13562)
* storage/remote: disable resharding during active retry backoffs

Today, remote_write reshards based on pure throughput. This is
problematic if throughput has been diminished because of HTTP 429s;
increasing the number of shards due to backpressure will only exacerbate
the problem.

This commit disables resharding for twice the retry backoff, ensuring
that resharding will never occur during an active backoff, and that
resharding does not become enabled again until enough time has elapsed
to allow any pending requests to be retried.

Signed-off-by: Robert Fratto <robertfratto@gmail.com>

* storage/remote: test that resharding is disabled on retry

Signed-off-by: Robert Fratto <robertfratto@gmail.com>

* storage/remote: address review feedback

Signed-off-by: Robert Fratto <robertfratto@gmail.com>

* storage/remote: track time where resharding initially got disabled

This change introduces a second atomic int64 to roughly track when
resharding got disabled. This int64 is only updated after updating the
disabled timestamp if resharding was previously enabled.

Signed-off-by: Robert Fratto <robertfratto@gmail.com>

---------

Signed-off-by: Robert Fratto <robertfratto@gmail.com>
2024-02-28 14:28:39 -08:00
..
azuread
otlptranslator otlptranslator: Upgrade to v0.95.0 2024-02-22 09:12:07 +01:00
chunked.go
chunked_test.go
client.go remote client: apply custom headers before sigv4 transport 2024-01-30 09:27:00 -05:00
client_test.go
codec.go Move from golang.org/x/exp/slices into slices now that we only support Go >= 1.21 2024-02-28 14:54:53 +01:00
codec_test.go storage/remote: improve symbol-table handling 2024-02-23 13:50:27 +00:00
ewma.go
intern.go
intern_test.go
max_timestamp.go
metadata_watcher.go
metadata_watcher_test.go
queue_manager.go storage/remote: disable resharding during active retry backoffs (#13562) 2024-02-28 14:28:39 -08:00
queue_manager_test.go storage/remote: disable resharding during active retry backoffs (#13562) 2024-02-28 14:28:39 -08:00
read.go
read_handler.go Move from golang.org/x/exp/slices into slices now that we only support Go >= 1.21 2024-02-28 14:54:53 +01:00
read_handler_test.go
read_test.go storage/remote: improve symbol-table handling 2024-02-23 13:50:27 +00:00
storage.go
storage_test.go
write.go
write_handler.go storage/remote: improve symbol-table handling 2024-02-23 13:50:27 +00:00
write_handler_test.go storage/remote: improve symbol-table handling 2024-02-23 13:50:27 +00:00
write_test.go