Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement functional logger attributes #527

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

charlespascoe
Copy link

I've implemented a simple feature to allow defining functional attributes when creating loggers. This allows things like global flags/state to be included in logs automatically without explicitly having to pass them into each log message. I've also added a tests.

@charlespascoe
Copy link
Author

I think that this feature would be really useful; I've created a hack to monkey patch this feature onto a Bunyan logger, but I can't be the only one who wants this feature. What does everyone else think?

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

Successfully merging this pull request may close these issues.

2 participants