Skip to content

Comments

fix log stdlibadapter when prefixed#1036

Merged
peterbourgon merged 4 commits intogo-kit:masterfrom
soven:fix-log-stdlibadapter-when-prefixe
Nov 25, 2020
Merged

fix log stdlibadapter when prefixed#1036
peterbourgon merged 4 commits intogo-kit:masterfrom
soven:fix-log-stdlibadapter-when-prefixe

Conversation

@soven
Copy link
Contributor

@soven soven commented Nov 16, 2020

No description provided.

log/stdlib.go Outdated
return func(a *StdlibAdapter) { a.messageKey = key }
}

// Prefix sets value of the prefix for the actual log message. By default, there's no prefix.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does setting the prefix do?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It allows client code to use the adapter for stdlib logger which is set by the prefix. There is an example in the issue.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please add some more detail to the doc comment?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure. done

@soven soven requested a review from peterbourgon November 24, 2020 07:30
@soven
Copy link
Contributor Author

soven commented Nov 24, 2020

looks like something wrong with the CI

@peterbourgon peterbourgon merged commit a055839 into go-kit:master Nov 25, 2020
@peterbourgon
Copy link
Member

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants