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

Add support for customizing the prefix format #578

Closed
santigl opened this issue Sep 14, 2020 · 2 comments · Fixed by #554
Closed

Add support for customizing the prefix format #578

santigl opened this issue Sep 14, 2020 · 2 comments · Fixed by #554
Assignees
Milestone

Comments

@santigl
Copy link
Contributor

santigl commented Sep 14, 2020

glog uses a fixed format for the prefix that is attached to log messages, which seems to follow what Google's internal tools expect (#229 (comment)).

However, other users of glog could need to integrate with tools that expect other formats, or would like to make the information more human-friendly (for example, by showing the full names of log levels instead of their initials), or might want to display the date in other timezones. They might also want to replace another logging library that has its own format and start using glog.

It would be great if glog allowed users of the library to specify their own prefix format. The current format would remain the default, and if the implementation is gated behind a compile-time flag, there wouldn't be any penalty for users that do not need the functionality.

@drigz
Copy link
Member

drigz commented Oct 5, 2020

@sergiud Any thoughts about this and the linked PR?

@elftech
Copy link

elftech commented Dec 4, 2020

I'm looking forward to this too.

@sergiud sergiud linked a pull request Mar 31, 2021 that will close this issue
@sergiud sergiud self-assigned this Apr 4, 2021
@sergiud sergiud added this to the 0.5 milestone Apr 4, 2021
@sergiud sergiud mentioned this issue May 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants