You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
t.client.Config.Logger.Log(fmt.Sprintf("WARN: failed to get session token, falling back to IMDSv1: %v", requestFailureError))
Even though the SDK is configured with LogOff log level by default, the line still gets printed to the stdout. Since we're using this library in the upstream project (see related open-telemetry/opentelemetry-collector-contrib#22807 (comment)), we wish not to log messages from the SDK but rather to handle any errors returned by the SDK.
Apologies for the late response. I agree with you that logOff shouldn't log anything else. This took a bit to root cause and seems like it was a design choice. I have patched this particular warning, but there might be other warnings surfaced in the SDK that we do not have visibility to.
Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.
Describe the bug
In token provider which is part of the EC2 metadata service, the logging decision is not respected in this part of the code:
aws-sdk-go/aws/ec2metadata/token_provider.go
Line 68 in 394d04f
Even though the SDK is configured with
LogOff
log level by default, the line still gets printed to the stdout. Since we're using this library in the upstream project (see related open-telemetry/opentelemetry-collector-contrib#22807 (comment)), we wish not to log messages from the SDK but rather to handle any errors returned by the SDK.Expected Behavior
No to see any SDK logs
Current Behavior
SDK logs a warning message to stdout
Reproduction Steps
The issues should be self explanatory without reproduction, but simplest way to reproduce would be to follow scenario described in open-telemetry/opentelemetry-collector-contrib#22807 (comment)
Possible Solution
No response
Additional Information/Context
No response
SDK version used
v1.49.1
Environment details (Version of Go (
go version
)? OS name and version, etc.)1.21.5
The text was updated successfully, but these errors were encountered: