Skip to content

fix(v2): ignore client timeouts in write-path circuit breaker #3858

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

Merged
merged 1 commit into from
Jan 21, 2025

Conversation

kolesnikovae
Copy link
Collaborator

Currently, client timeouts may trigger the segment-writer client circuit breaker, causing a specific segment-writer service instance to be temporarily removed from the connection pool. On one hand, this behavior is justified because if one of the instances is temporarily overloaded (e.g., due to a burst), we want to send fewer requests to it.

In practice, however, this is a very rare case, and the adaptive load balancing we have is usually fast enough to prevent hot spots. What we may observe instead is that either all the instances are overloaded (evenly) or the client (the distributor) itself is overloaded. In such cases, the availability of the write path might degrade due to circuit breaker flapping. Another interesting side effect is an increase in the number of segments created (because more than one segment-writer will be uploading data for each shard), leading to additional pressure on the compaction process.

@kolesnikovae kolesnikovae requested a review from a team as a code owner January 21, 2025 07:14
@kolesnikovae kolesnikovae merged commit 7f810f7 into main Jan 21, 2025
19 checks passed
@kolesnikovae kolesnikovae deleted the fix/write-path-circuit-breaker branch January 21, 2025 08:24
shelldandy pushed a commit to shelldandy/pyroscope that referenced this pull request Mar 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants