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

Feature: Add JSON logs support #177

Open
so0k opened this issue Apr 1, 2023 · 0 comments
Open

Feature: Add JSON logs support #177

so0k opened this issue Apr 1, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@so0k
Copy link

so0k commented Apr 1, 2023

Currently log message format requires custom parsing to extract relevant fields in log indexing solutions:

return []byte(fmt.Sprintf("%s %s %s[%d]: %s %s\n", timestamp, hostname, tag, os.Getpid(), strings.ToUpper(entry.Level.String()), entry.Message)), nil

However, the used log library used does support advanced JSON logs, making the fields easily indexed sirupsen/logrus example.

If there's interest, I'd add a flag to switch on JSON logs?

@abtreece abtreece added the enhancement New feature or request label Apr 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants