A high-performance structured logger for Go built for 12-factor apps with developer-friendly terminal output.
logxi is a structured logging library for Go that follows the 12-factor app methodology. It outputs machine-parsable JSON in production environments while providing colorful, readable formatting for development, balancing performance with developer experience.
Go developers building production applications who need efficient, structured logging with minimal performance overhead and easy runtime configuration.
Developers choose logxi for its benchmarked 2x faster JSON encoding compared to alternatives like logrus and log15, along with built-in level guards to avoid argument building costs and environment-based configuration without code changes.
A 12-factor app logger built for performance and happy development
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
logxi encodes JSON 2x faster than logrus and log15 for primitive types, with level guards to avoid unnecessary argument building costs, as shown in detailed benchmarks.
Enforces key-value pair arguments and defaults to JSON output in non-terminal environments, ensuring logs are machine-parsable for production without extra configuration.
Provides colorful terminal output with file/line numbers for traces and errors, plus call stacks, making development and troubleshooting more intuitive and efficient.
Allows enabling/disabling loggers and setting levels via LOGXI environment variables without code changes, adhering to 12-factor app principles for flexible runtime control.
Lacks built-in support for hooks to external monitoring systems, requiring custom io.Writer implementations or external filters for integration, which adds development overhead.
Colorful output is not well-supported in native Windows terminals like PowerShell, necessitating third-party tools like ConEmu for a decent experience, limiting out-of-the-box usability.
Does not include log rotation features; relies on external utilities like rotatelogs, which can complicate deployment and add operational dependencies.