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] Make logs (printed from spdlog) sended to trace_pipe on agent #279

Closed
Officeyutong opened this issue Apr 14, 2024 · 6 comments
Closed
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@Officeyutong
Copy link
Contributor

We should support that make logs printed from spdlog being sended to trace_pipt, not directly printed from the process injected by agent

@Officeyutong Officeyutong added enhancement New feature or request good first issue Good for newcomers labels Apr 14, 2024
@NobinPegasus
Copy link
Contributor

@Officeyutong I would like to work on this

@NobinPegasus
Copy link
Contributor

@Officeyutong
Can you provide some guidelines? Which files should I make the changes to? SPDLOG_* are used in far too many places.

@Officeyutong
Copy link
Contributor Author

@Officeyutong Can you provide some guidelines? Which files should I make the changes to? SPDLOG_* are used in far too many places.

Create a new logger, set it to default, and use a customized sink so it could send logs to tracepipe

https://github.com/gabime/spdlog/wiki/2.-Creating-loggers

@yunwei37
Copy link
Member

yunwei37 commented May 6, 2024

@NobinPegasus Any progress?

@Kailian-Jacy
Copy link
Contributor

Kailian-Jacy commented Jun 3, 2024

Hi, I've made a draft pr to this issue with basic logging redirection feature finished:

#301

There are still some questions too be solved before further works and merging. Please kindly provide suggestions if possible.

I may add these feature in this PR, hoping suggestions or confirmation from you:

  • Provide a subcommand similar to trace to output logs we want.
  • Logs be optionally reserved under /var/log/ or syslog under linux. Log rotation are management automatically.
  • Merge logs from different processes as one. Add tags of source (which injected process causing) to the log.
  • Add documentations about logging.

@Officeyutong
Copy link
Contributor Author

Hi, I've made a draft pr to this issue with basic logging redirection feature finished:

#301

There are still some questions too be solved before further works and merging. Please kindly provide suggestions if possible.

I may add these feature in this PR, hoping suggestions or confirmation from you:

  • Provide a subcommand similar to trace to output logs we want.
  • Logs be optionally reserved under /var/log/ or syslog under linux. Log rotation are management automatically.
  • Merge logs from different processes as one. Add tags of source (which injected process causing) to the log.
  • Add documentations about logging.

These features are ok. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants