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

logging: Deprecate and remove the logfmt encoder #3575

Closed
mholt opened this issue Jul 13, 2020 · 0 comments
Closed

logging: Deprecate and remove the logfmt encoder #3575

mholt opened this issue Jul 13, 2020 · 0 comments
Assignees
Labels
bug 🐞 Something isn't working discussion 💬 The right solution needs to be found
Milestone

Comments

@mholt
Copy link
Member

mholt commented Jul 13, 2020

The logfmt encoder is a very simple key=val format for logs. Unfortunately, it does not support nested structures, which are common in structured logging, even though it could flatten them into a simple key=val sequence. But it doesn't. It's basically broken.

It was probably a mistake to include this encoder in our standard modules, since it yields errors on many log entries, occluding a lot of information that all other formats display just fine.

I'm going to deprecate this module and eventually remove it from our standard modules before more users start relying on it. However, it will still be available in a separate repo just like any other module.

Using this module will emit a warning-level log that logfmt is going to be removed, with a link to this issue. We will eventually remove it from the code base and move it into another repo. (Edit: decided we will just move it to another repo if there's enough demand for it)

To clarify: the logfmt module will still be available, but not by default, as it is essentially broken. Instead of sweeping the bug under the rug, this will call it out to attention, which is better.

@mholt mholt added in progress 🏃‍♂️ Being actively worked on discussion 💬 The right solution needs to be found labels Jul 13, 2020
@mholt mholt added this to the 2.x milestone Jul 13, 2020
@mholt mholt added the bug 🐞 Something isn't working label Jul 13, 2020
@mholt mholt self-assigned this Jul 13, 2020
mholt added a commit that referenced this issue Jul 13, 2020
It is essentially broken because it occludes many log fields.

See: #3575
@mholt mholt modified the milestones: 2.x, v2.4.0 Dec 2, 2020
@mholt mholt closed this as completed in ef54483 Jan 7, 2021
@mholt mholt removed the in progress 🏃‍♂️ Being actively worked on label Jan 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐞 Something isn't working discussion 💬 The right solution needs to be found
Projects
None yet
Development

No branches or pull requests

2 participants
@mholt and others