-
Notifications
You must be signed in to change notification settings - Fork 30
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 on standard err #26
Comments
For reference:
|
Hi, can you help me understand what problem you're trying to solve by having the agent write to stdout? My understanding is that the usual pattern is: program output -> stdout, program logs -> stderr. Given that the "output" of the agent is Honeycomb events and the logs emitted by the agent are mostly for debugging and informational purposes, this seems appropriate, but maybe I am missing something. |
… warn to stdout Addresses #26 by providing a new config option, `splitLogging`, to enable certain log severities to go to stdout rather than stderr. I chose to make this optional as I do not want to introduce new behavior into the agent for all users, which may rely on everything going to stderr.
Hi @tredman, Sure. In Google Stackdriver if you pipe to stderr it will automatically assume it's an error no matter what Thanks for responding so quickly! |
Hi @freddd and @mariana-bocoi - we've patched our agent to allow optionally splitting stdout and stderr by severity. (trace, debug, info, warn to stdout, everything higher to stderr) It's sort of a workaround as we don't have the cycles to swap out our log lib at the moment. If you redeploy the agent with the latest image and specify |
Thanks! |
It seems like the logging library used (github.com/Sirupsen/logrus) logs everything to stderr.
@freddd says that it’s a known
logrus
problem and would suggest using https://github.com/uber-go/zap instead).The text was updated successfully, but these errors were encountered: