Closed dbhoot closed 5 months ago
@imroc what are your thoughts on this change? Please review when you have a moment.
I think it's better to rename to NewLoggerFromStandardLogger
, a bit longer, but no ambiguity.
I think it's better to rename to
NewLoggerFromStandardLogger
, a bit longer, but no ambiguity.
I agree. I was thinking of making that change anyway. Good call.
NewFromStandardLogger --> NewLoggerFromStandardLogger
Thanks
@imroc do we need a new release for this?
Released at v3.43.3
Previously
You could not create a req.Logger from a log.Logger. Instead, you have to create one from an io.Writer.
Unfortunately, there are situations when you do not have access to the underlying io.Writer for your .Logger. This limits your ability to set the client logger using the tooling of your choice.
Now
You can usually convert your.Logger into a log.Logger. With this PR, you're now able to create a req.Logger from a log.Logger and set your client logger as needed.