Repository navigation
[Bugfix][Router] Retry a failed dynamic config slowly instead of every check - #1184
Open
shubhamkapoor01 wants to merge 4 commits into
Open
shubhamkapoor01 wants to merge 4 commits into
shubhamkapoor01 wants to merge 4 commits into
Conversation
Signed-off-by: shubhamkapoor01 <66124414+shubhamkapoor01@users.noreply.github.com>
Signed-off-by: shubhamkapoor01 <66124414+shubhamkapoor01@users.noreply.github.com>
…y check Signed-off-by: Shubham Kapoor <66124414+shubhamkapoor01@users.noreply.github.com>
shubhamkapoor01
requested review from
ApostaC,
Shaoting-Feng,
YuhanLiu11 and
ruizhang0101
as code owners
October 29, 2026 12:18
3 tasks done
Contributor
There was a problem hiding this comment.
Code Review
This pull request introduces a retry mechanism for failed configuration reloads in the DynamicConfigWatcher. When a configuration fails to apply (for example, if a callbacks module is not yet importable), the watcher will now skip a set number of checks before retrying, rather than failing indefinitely or spamming retries. Corresponding unit tests have been added to verify this behavior. The feedback points out that when reconfigure_all raises an exception, it is caught and re-raised to an outer block that logs a misleading "Error loading config file" message. It is recommended to handle this exception directly in the inner block to provide a more accurate "Error applying config" warning.
Signed-off-by: Shubham Kapoor <66124414+shubhamkapoor01@users.noreply.github.com>
This branch has not been deployed
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.
If a new config fails to apply and the file stays as is, the watcher reapplies it on every check (10s by default), rebuilding service discovery each time. A failed config is now skipped for the next 30 checks before it is retried. It usually fails the same way again, but not always: a callbacks module can become importable later, so it isn't skipped forever. Any change to the config is applied at once, and going back to the last good config is still reapplied, as in #1177. Follows up #1177, from @chrikrah's review.
This is on top of #1177, so its two commits show here until that one is merged; only the last commit is new.
-swhen doinggit commit[Bugfix],[Feat], and[CI].