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

Machine readable drenv logs #1307

Open
nirs opened this issue Mar 31, 2024 · 0 comments
Open

Machine readable drenv logs #1307

nirs opened this issue Mar 31, 2024 · 0 comments
Labels
enhancement New feature or request test Testing related issue

Comments

@nirs
Copy link
Member

nirs commented Mar 31, 2024

Current drenv logs are hard to process by a machine.

Instead of text based logs, use jsonlines format:

$ drenv start --json envs/regional-dr.yaml
{"time": "2024-03-31 11:24:09,869", "level": "DEBUG", "context": "main", "message": "Created new process group 105239"}
{"time": "2024-03-31 11:24:09,869", "level": "INFO", "context": "rdr", "message": "Starting environment"}

This allow the tool running drenv to process logs and display interesting events while
storing the logs to file.

It also allows easier processing of the logs later to compute stats.

The implementation is easy, using a json Formatter

@nirs nirs added enhancement New feature or request test Testing related issue labels Mar 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request test Testing related issue
Projects
None yet
Development

No branches or pull requests

1 participant