https://github.com/rs/zerolog

golang json logging structured-logging zerolog

Last synced: about 1 month ago

Repository metadata:

Zero Allocation JSON Logger


Owner metadata:


Committers metadata

Last synced: about 1 month ago

Total Commits: 358
Total Committers: 162
Avg Commits per committer: 2.21
Development Distribution Score (DDS): 0.615

Commits in past year: 29
Committers in past year: 22
Avg Commits per committer in past year: 1.318
Development Distribution Score (DDS) in past year: 0.897

Name Email Commits
Olivier Poitrey rs@r****t 138
Mitar m****t@t****m 17
dependabot[bot] 4****] 11
Ravi Raju r****r@e****g 8
Dan Gillis g****t@g****m 5
hn8 1****8 4
Jason McVetta j****a@g****m 3
Eugene r****r@b****t 2
Dušan Kasan d****n@k****k 2
Garret Buell g****l@g****m 2
Giovanni Bajo r****y@d****m 2
Karel Minarik k****k@g****m 2
Naveen n****a@g****m 2
Nicola Murino n****o@g****m 2
Veselkov Konstantin k****b@g****m 2
Pavel Griaznov g****t@g****m 2
Mike Camp m****p@g****m 2
nichady 5****y 2
hazimj 4****j 2
adw1n a****n 2
Sergey 8****o 2
Rodrigo Coelho r****o 2
Ingmar Stein I****n 2
Giuseppe g****2 2
Robson Roberto Souza Peixoto 1****o 1
Scott Davis 1****o 1
Sean 7****n 1
Steve Carlson s****n 1
Stig Otnes Kolstad s****k 1
Marc M. Adkins m****3 1
and 132 more...

Issue and Pull Request metadata

Last synced: about 1 month ago


Package metadata

go: github.com/rs/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:

  • Homepage: https://github.com/rs/zerolog
  • Documentation: https://pkg.go.dev/github.com/rs/zerolog#section-documentation
  • Licenses: MIT
  • Latest release: v1.31.0 (published about 1 year ago)
  • Last Synced: 2024-11-11T01:14:15.279Z (about 1 month ago)
  • Versions: 51
  • Dependent Packages: 14,089
  • Dependent Repositories: 32,224
  • Docker Downloads: 6,431,394,785
  • Rankings:
    • Dependent packages count: 0.013%
    • Dependent repos count: 0.032%
    • Docker downloads count: 0.044%
    • Average: 0.42%
    • Stargazers count: 0.696%
    • Forks count: 1.317%
go: github.com/rs/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: There is no fields deduplication out-of-the-box. Using the same key multiple times creates new key in final JSON each time. However, it’s not a big deal though as JSON accepts dup keys, the last one prevails.

  • Homepage: https://github.com/rs/zeroLog
  • Documentation: https://pkg.go.dev/github.com/rs/zeroLog#section-documentation
  • Licenses: MIT
  • Latest release: v1.31.0 (published about 1 year ago)
  • Last Synced: 2024-11-11T01:14:12.096Z (about 1 month ago)
  • Versions: 51
  • Dependent Packages: 0
  • Dependent Repositories: 1
  • Rankings:
    • Stargazers count: 0.738%
    • Forks count: 1.35%
    • Average: 3.834%
    • Dependent repos count: 4.794%
    • Dependent packages count: 8.453%
go: github.com/rs/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: There is no fields deduplication out-of-the-box. Using the same key multiple times creates new key in final JSON each time. However, it’s not a big deal though as JSON accepts dup keys, the last one prevails.

  • Homepage: https://github.com/rs/zeroloG
  • Documentation: https://pkg.go.dev/github.com/rs/zeroloG#section-documentation
  • Licenses: MIT
  • Latest release: v1.31.0 (published about 1 year ago)
  • Last Synced: 2024-11-11T01:14:31.082Z (about 1 month ago)
  • Versions: 51
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Stargazers count: 0.513%
    • Forks count: 0.878%
    • Average: 4.434%
    • Dependent packages count: 6.999%
    • Dependent repos count: 9.346%
go: github.com/rs/zerolog/cmd/lint

  • Homepage: https://github.com/rs/zerolog
  • Documentation: https://pkg.go.dev/github.com/rs/zerolog/cmd/lint#section-documentation
  • Licenses: MIT
  • Latest release: (published 8 months ago)
  • Last Synced: 2024-11-06T23:01:58.579Z (about 1 month ago)
  • Versions: 0
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Stargazers count: 0.513%
    • Forks count: 0.878%
    • Average: 4.434%
    • Dependent packages count: 6.999%
    • Dependent repos count: 9.346%
go: github.com/RS/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: There is no fields deduplication out-of-the-box. Using the same key multiple times creates new key in final JSON each time. However, it’s not a big deal though as JSON accepts dup keys, the last one prevails.

  • Homepage: https://github.com/RS/zerolog
  • Documentation: https://pkg.go.dev/github.com/RS/zerolog#section-documentation
  • Licenses: MIT
  • Latest release: v1.31.0 (published about 1 year ago)
  • Last Synced: 2024-11-11T01:14:14.319Z (about 1 month ago)
  • Versions: 51
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Stargazers count: 0.513%
    • Forks count: 0.878%
    • Average: 4.434%
    • Dependent packages count: 6.999%
    • Dependent repos count: 9.346%
go: github.com/rs/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: There is no fields deduplication out-of-the-box. Using the same key multiple times creates new key in final JSON each time. However, it’s not a big deal though as JSON accepts dup keys, the last one prevails.

  • Homepage: https://github.com/rs/Zerolog
  • Documentation: https://pkg.go.dev/github.com/rs/Zerolog#section-documentation
  • Licenses: MIT
  • Latest release: v1.31.0 (published about 1 year ago)
  • Last Synced: 2024-11-11T01:14:42.220Z (about 1 month ago)
  • Versions: 51
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Stargazers count: 0.681%
    • Forks count: 1.26%
    • Average: 5.381%
    • Dependent packages count: 8.883%
    • Dependent repos count: 10.7%
go: github.com/rs/zerolog/internal/json

go: github.com/rs/zerolog/pkgerrors

go: github.com/rs/zerolog/log

Package log provides a global logger for zerolog. This example uses command-line flags to demonstrate various outputs depending on the chosen log level.

  • Homepage: https://github.com/rs/zerolog
  • Documentation: https://pkg.go.dev/github.com/rs/zerolog/log#section-documentation
  • Licenses: MIT
  • Latest release:
  • Last Synced: 2024-11-03T21:31:42.854Z (about 2 months ago)
  • Versions: 0
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Dependent packages count: 6.151%
    • Average: 6.357%
    • Dependent repos count: 6.563%
go: github.com/RS/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: There is no fields deduplication out-of-the-box. Using the same key multiple times creates new key in final JSON each time. However, it’s not a big deal though as JSON accepts dup keys, the last one prevails.

  • Homepage: https://github.com/RS/ZEROLOG
  • Documentation: https://pkg.go.dev/github.com/RS/ZEROLOG#section-documentation
  • Licenses: MIT
  • Latest release:
  • Last Synced: 2024-11-11T01:14:11.168Z (about 1 month ago)
  • Versions: 51
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Dependent packages count: 6.292%
    • Average: 6.505%
    • Dependent repos count: 6.717%
go: 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:

  • Homepage: https://github.com/rs/zerolog
  • Documentation: https://pkg.go.dev/github.com/rusriver/zerolog#section-documentation
  • Licenses: MIT
  • Latest release: (published 8 months ago)
  • Last Synced: 2024-11-06T23:02:00.842Z (about 1 month ago)
  • Versions: 0
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Rankings:
    • Dependent packages count: 7.044%
    • Average: 7.494%
    • Dependent repos count: 7.943%
pypi: pyzerolog

Package that makes typed logging convinient.

  • Homepage:
  • Documentation: https://pyzerolog.readthedocs.io/
  • Licenses: MIT License
  • Latest release: 0.4.0 (published about 2 years ago)
  • Last Synced: 2024-11-11T01:14:54.885Z (about 1 month ago)
  • Versions: 7
  • Dependent Packages: 0
  • Dependent Repositories: 1
  • Downloads: 420 Last month
  • Docker Downloads: 90
  • Rankings:
    • Docker downloads count: 2.768%
    • Dependent packages count: 10.02%
    • Dependent repos count: 21.705%
    • Average: 22.925%
    • Downloads: 57.206%
  • Maintainers (1)

Dependencies

.github/workflows/test.yml actions
  • actions/cache v3 composite
  • actions/checkout v3 composite
  • actions/setup-go v3 composite
cmd/lint/go.mod go
  • golang.org/x/tools v0.1.8
cmd/lint/go.sum go
  • github.com/yuin/goldmark v1.4.1
  • golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2
  • golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550
  • golang.org/x/mod v0.5.1
  • golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3
  • golang.org/x/net v0.0.0-20190620200207-3b0461eec859
  • golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f
  • golang.org/x/sync v0.0.0-20190423024810-112230192c58
  • golang.org/x/sync v0.0.0-20210220032951-036812b2e83c
  • golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a
  • golang.org/x/sys v0.0.0-20190412213103-97732733099d
  • golang.org/x/sys v0.0.0-20201119102817-f84b799fce68
  • golang.org/x/sys v0.0.0-20210423082822-04245dca01da
  • golang.org/x/sys v0.0.0-20211019181941-9d821ace8654
  • golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1
  • golang.org/x/text v0.3.0
  • golang.org/x/text v0.3.6
  • golang.org/x/text v0.3.7
  • golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e
  • golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e
  • golang.org/x/tools v0.1.8
  • golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7
  • golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898
  • golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1
go.mod go
  • github.com/coreos/go-systemd/v22 v22.3.3-0.20220203105225-a9a7ef127534
  • github.com/mattn/go-colorable v0.1.12
  • github.com/pkg/errors v0.9.1
  • github.com/rs/xid v1.4.0
go.sum go
  • github.com/coreos/go-systemd/v22 v22.3.3-0.20220203105225-a9a7ef127534
  • github.com/godbus/dbus/v5 v5.0.4
  • github.com/mattn/go-colorable v0.1.12
  • github.com/mattn/go-isatty v0.0.14
  • github.com/pkg/errors v0.9.1
  • github.com/rs/xid v1.4.0
  • golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c
  • golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6