What registration levels are available for Heroku?

I have a Rails application running on Heroku, it works fine. I worked with a debug log, but now I'm back to INFO. What other debugging levels are available? And when starting up for production, what level of registration should I use?

+4
source share
2 answers

In Heroku, you can set the log level using the LOG_LEVEL environment variable

$ heroku config:set LOG_LEVEL=DEBUG 

Valid values ​​include DEBUG, INFO, WARN, ERROR, and FATAL. Alternatively, you can set this value in your environment configuration:

 config.log_level = :debug 

If both parameters are set, then LOG_LEVEL will take precedence. You most likely want INFO in production.

See the pearl rails-stdout-logging

+9
source

Logging into Heroku is just a stream of text strings. This way you can register whatever you want. You can also filter this stream, use add-ons for advanced searches, and receive syslog log drainage.

+1
source

Source: https://habr.com/ru/post/1412291/


All Articles