fix(xds): do not log 'no keys' as an error when an xds key has no data - #13758
Open
AlinsRan wants to merge 1 commit into
Open
fix(xds): do not log 'no keys' as an error when an xds key has no data#13758AlinsRan wants to merge 1 commit into
AlinsRan wants to merge 1 commit into
Conversation
_automatic_fetch logged every non-nil error from sync_data, including the "no keys" sentinel that config.new returns when an xds key simply has no data yet. The periodic fetch loop already treats "no keys" as non-error (err ~= "no keys"); this makes _automatic_fetch consistent, so a config provider watching an empty xds key no longer spams error.log at startup. Signed-off-by: AlinsRan <alinsran@apache.org>
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.
Description
_automatic_fetchlogs every non-nil error returned bysync_data, including the"no keys"sentinel thatconfig.newreturns when an xds key simply has no data yet:The periodic fetch loop a few lines up already treats
"no keys"as non-error (err ~= "no keys"). This makes_automatic_fetchconsistent with it, so a config provider watching an empty xds key no longer spamserror.logat startup.Which issue(s) this PR fixes
Removes spurious
failed to fetch data from xds no keyserror-log lines for xds keys that are legitimately empty.Checklist
err ~= "no keys"filter the periodic loop already applies, and the xds test harness needs a preloaded.so, so there is no lightweight unit for the empty-key path