Closed nihonjinrxs closed 4 years ago
Thanks for sharing that link! loggit
does, and will always, default to file-based logging, as it's not explicitly designed for the use cases intended for that methodology:
The twelve-factor app is a methodology for building software-as-a-service apps [...]
But I can certainly see if I can get STDOUT logging to work as you describe, as an option.
Would be appreciated, since most apps out there these days are software-as-a-service, also known as web apps and web apis.
Note to self: I added an echo
argument some time ago, but it doesn't log the JSON to stdout
, just a regular text log entry. Need to configure to log the JSON. Will need to make sure the escaped quotes in the JSON aren't present in stdout
.
Done, will appear in v2.0.0.
In many of our production contexts, we log, usually in JSON, to STDOUT (or in rare cases STDERR), and have external log collectors that capture logs across many services.
The filename test in
configurations.R
seems to prevent me from doing what I'd normally do for this:I think it would be helpful to allow for these basic streams as output.
This is also in concert with the logging factor of the 12-factor app, which recommends: