aws-sdk-rust
aws-sdk-rust copied to clipboard
Switch to debug logging for credential fetches
Motivation and Context
These messages really feel like debug messages. After starting to use the SDK, it's somewhat jarring to see a bunch of pretty irrelevant information outputted and it is also somewhat annoying to disable info logging just for the AWS SDK.
It's of course simpleish and possible to do, but it's just that these messages don't seem to be actually useful information:
2024-03-21T19:59:29.282801Z INFO x:lazy_load_identity: aws_config::profile::credentials: constructed abstract provider from config file chain=ProfileChain { base: CredentialProcess("xxx ** arguments redacted **"), chain: [] }
2024-03-21T19:59:29.283008Z INFO x:lazy_load_identity: aws_config::profile::credentials::exec: first credentials will be loaded from CredentialProcess("xxx ** arguments redacted **") base=CredentialProcess("xxx ** arguments redacted **")
2024-03-21T19:59:30.613478Z INFO x:lazy_load_identity: aws_config::profile::credentials: loaded base credentials creds=Credentials { provider_name: "CredentialProcess", access_key_id: "ASIAWXV3OIC7xxx", secret_access_key: "** redacted **", expires_after: "2024-03-21T20:10:36Z" }
What information is this actually giving me? That it worked as expected Excellent! But I don't need to see that logged to know that.
The fix is to just disable info logging in the SDK, but info messages can be useful - I don't really want to disable it wholesale.
Can we just change these to a more appropriate debug level?
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Hi @orf, thank you for submitting the proposed changes! What you're describing seems reasonable to me. Could you do us a favor and submit a PR to smithy-rs instead (as described in CONTRIBUTING)? That way, your name properly appears in contributors in release notes when a release goes out.
Sure! Will do!
Remade here: https://github.com/smithy-lang/smithy-rs/pull/3546