Skip to main content

Structured logging

Your Runnable code can log to Atmo's structured output using the logging methods.

In Rust these methods are available under the log module:

# Use the "log" module
use suborbital::log;

# Invoke the "Info" method
log::info(…)

The following namespace methods are available:

Info​

Logs the message with the 'info' level:

STATUS: STABLE
pub fn info(msg: &str)

Warn​

Logs the message with the 'warn' level:

STATUS: STABLE
pub fn warn(msg: &str)

Error​

Logs the message with the 'err' level:

STATUS: STABLE
pub fn error(msg: &str)

Debug​

Logs the message with the 'debug' level:

STATUS: STABLE
pub fn debug(msg: &str)