Skip to content

ybshen/steno

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Steno

Steno is a lightweight, modular logging library written specifically to support Cloud Foundry.

Concepts

Steno is composed of three main classes: loggers, sinks, and formatters. Loggers are the main entry point for Steno. They consume user input, create structured records, and forward said records to the configured sinks. Sinks are the ultimate destination for log records. They transform a structured record into a string via a formatter and then typically write the transformed string to another transport.

Getting started

config = Steno::Config.new(
  :sinks   => [Steno::Sink::IO.new(STDOUT)],
  :codec   => Steno::Codec::Json.new,
  :context => Steno::Context::ThreadLocal.new)

Steno.init(config)

logger = Steno.logger("test")

logger.info("Hello world!")

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published