-
Notifications
You must be signed in to change notification settings - Fork 4.6k
xds: Avoid error logs when setting fallback bootstrap config #8419
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
Conversation
FYI @apolcyn |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #8419 +/- ##
==========================================
+ Coverage 82.26% 82.40% +0.14%
==========================================
Files 414 414
Lines 40424 40426 +2
==========================================
+ Hits 33255 33314 +59
+ Misses 5802 5757 -45
+ Partials 1367 1355 -12
🚀 New features to boost your workflow:
|
t.Run(name, func(t *testing.T) { | ||
testGetConfigurationWithFileNameEnv(t, name, true, nil) | ||
testGetConfigurationWithFileContentEnv(t, name, true, nil) | ||
}) | ||
} | ||
name := "empty" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: const
please.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed.
* xdsclient: preserve original bytes for decoding when the resource is wrapped (#8411) * xds: Avoid error logs when setting fallback bootstrap config (#8419) * xdsclient: relay marshalled bytes of complete resource proto to decoders (#8422) * xds: give up pool lock before closing xdsclient channel (#8445) * transport: release mutex before returning on expired deadlines in server streams (#8451) --------- Co-authored-by: Easwar Swaminathan <easwars@google.com> Co-authored-by: Arjan Singh Bal <46515553+arjan-bal@users.noreply.github.com> Co-authored-by: Purnesh Dixit <purneshdixit@google.com> Co-authored-by: Doug Fawley <dfawley@google.com>
Initially, there was no error log when setting the fallback bootstrap config. The GetConfiguration function would first attempt to read the bootstrap configuration from environment variables and then fall back to the configuration provided by the c2p resolver.
A subsequent change, which added an xDS client pool, modified this behavior. It read the bootstrap config within an init() function in clientimpl.go, preventing the c2p resolver from setting its fallback configuration after channel creation. A fix was implemented (#8050) to allow setting a fallback bootstrap config on an xDS client pool, but this introduced an error log when setting the fallback config twice. This happens when multiple c2p resolvers are created in the same process.
After that, #8164 reverted the behavior of reading the bootstrap in the init() function. This allows us to return to the original way—reading from environment variables and then falling back to the c2p resolver's config—without requiring an error log.
RELEASE NOTES:
Attempt to set a bootstrap configuration...
when creating multiple directpath channels.