[kyoto] tighten supervisor restart threshold to 15#489
Merged
0xsiddharthks merged 2 commits intosiddharth/kyoto-upgradefrom Apr 27, 2026
Merged
[kyoto] tighten supervisor restart threshold to 15#4890xsiddharthks merged 2 commits intosiddharth/kyoto-upgradefrom
0xsiddharthks merged 2 commits intosiddharth/kyoto-upgradefrom
Conversation
Lower KYOTO_MAX_CONSECUTIVE_FAILURES from 30 to 15. In bip157 >= 0.5.0, TrustedPeer::from_hostname is consumed on use — popped from the whitelist when first tried, never reinstated. Once the resolved-IP set for a hostname is exhausted, only a fresh Builder::build() will run lookup_host again, and our connectivity supervisor's rebuild path is that fresh build. At the previous threshold of 30 consecutive failures, a Kubernetes pod rotation that swaps the IPs of every whitelisted peer left us unavailable for several minutes while we burned through the cached resolution set 3x before rebuilding. 15 halves the worst-case recovery without churning during a normal single-peer flap. We can re-tune later from the kyoto_consecutive_failures and kyoto_restarts metrics.
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.
Lower
KYOTO_MAX_CONSECUTIVE_FAILURESfrom 30 to 15 so a Kubernetes pod rotation that swaps every whitelisted-peer IP recovers in tens of seconds rather than minutes.