Merged
Conversation
Member
Author
|
The CI failures were caused by the kit/tracing/opentracing package. |
| // Using a SyncLogger has the benefit that it guarantees each log event is | ||
| // handled atomically within the wrapped logger, but it typically serializes | ||
| // both the formatting and output logic. Use a SyncLogger if the formatting | ||
| // logger may perform multiple writes per log event. |
Member
There was a problem hiding this comment.
Amazing doc comment. Thank you.
Member
|
If you rebase on master, those build failures should go away. Assuming that's true, LGTM! If not, let me know and I'll take care of it. |
- Add sections for basic usage, log contexts, dynamic context values, and concurrent safety. - Add executable tests that illustrate the new topics. - Update README.md to use log.NewSyncWriter in examples.
581cb2d to
d235bef
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements #246. Simpler alternative to #273.
This PR adds two simple concurrency safety helpers to package log and also rewrites the package docs to help guide a new user gently into the log package. It also adds or rewrites several package level executable examples.
Please review. @peterbourgon