Global Logger

Log lines to scribe using the default global logger.

clog.global_state.check_create_default_loggers()

Set up global loggers, if necessary.

clog.global_state.log_line(stream, line)

Log a single line to the global logger(s). If the line contains any newline characters each line will be logged as a separate message. If this is a problem for your log you should encode your log messages.

Parameters:
  • stream – name of the scribe stream to send this log
  • line – contents of the log message
clog.global_state.reset_default_loggers()

Destroy the global clog loggers. This must be done when forking to ensure that children do not share a desynchronized connection to Scribe

Any writes after this call will cause the loggers to be rebuilt, so this must be the last thing done before the fork or, better yet, the first thing after the fork.