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 Request] Structured logging (KV) support #70

Open
3 tasks
SpriteOvO opened this issue Jul 25, 2024 · 0 comments
Open
3 tasks

[Feature Request] Structured logging (KV) support #70

SpriteOvO opened this issue Jul 25, 2024 · 0 comments
Labels
enhancement New feature or request
Milestone

Comments

@SpriteOvO
Copy link
Owner

SpriteOvO commented Jul 25, 2024

Structured logging enhances traditional text-based log records with user-defined attributes. Structured logs can be analyzed using a variety of data processing techniques, without needing to find and parse attributes from unstructured text first.

With JsonFormatter (PR #69) added, the KV can be injected into the output logs as a separated JSON object for parsing by third-party programs.

Implementation

Steps / History

  • Logging macros accepts a new optional parameter kv.
  • Add a new kv field in struct Record.
  • ... (We need to carefully consider how the API looks and is implemented)

A reference is the log kv implementation, we can see if we can improve anything base on that.

@SpriteOvO SpriteOvO added the enhancement New feature or request label Jul 25, 2024
@SpriteOvO SpriteOvO added this to the v0.5.0 milestone Jul 25, 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
Projects
None yet
Development

No branches or pull requests

1 participant