An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

Top 7.5% on proxy.golang.org

proxy.golang.org : github.com/rusriver/zerolog

Package zerolog provides a lightweight logging library dedicated to JSON logging. A global Logger can be use for simple logging: NOTE: To import the global logger, import the "log" subpackage "github.com/rs/zerolog/log". Fields can be added to log messages: Create logger instance to manage different outputs: Sub-loggers let you chain loggers with additional context: Level logging Customize automatic field names: Log with no level and message: Add contextual fields to global Logger: Sample logs: Log with contextual hooks: Field duplication: There is no fields deduplication out-of-the-box. Using the same key multiple times creates new key in final JSON each time. In this case, many consumers will take the last value, but this is not guaranteed; check yours if in doubt. Concurrency safety: Be careful when calling UpdateContext. It is not concurrency safe. Use the With method to create a child logger:

Registry - Source - Documentation - JSON
purl: pkg:golang/github.com/rusriver/zerolog
Keywords: golang , json , logging , structured-logging , zerolog
License: MIT
Latest release: 7 days ago
Namespace: github.com/rusriver
Stars: 11,809 on GitHub
Forks: 604 on GitHub
Total Commits: 361
Committers: 161
Average commits per author: 2.242
Development Distribution Score (DDS): 0.615
More commit stats: commits.ecosyste.ms
See more repository details: repos.ecosyste.ms
Last synced: 7 days ago