Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
New creates a logger based on SAMVERK_ENV.
- "development" or "dev": colorized console output, debug level
- anything else (including unset): structured JSON, info level
func NewWithTee ¶ added in v0.1.16
NewWithTee creates a logger that writes to both stdout and a SQLite log store. In production mode, a single JSON core tees through the logstore syncer. In dev mode, a console core writes to stdout and a separate JSON core writes to the logstore syncer.
The returned *logstore.Syncer can be used to attach a WebSocket broadcaster via SetBroadcaster after the server is constructed.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.