redis/extra/redisotel
Scott 7c4b924350
fix(redisotel): correct metrics.DialHook attrs (#2331)
2022-12-23 20:40:07 +08:00
..
README.md chore: improve instrumentation example 2022-10-12 17:18:55 +03:00
config.go chore: add more metrics to redisotel 2022-11-17 16:24:16 +02:00
go.mod chore: release v9.0.0-rc.2 (release.sh) 2022-11-26 14:20:33 +02:00
go.sum chore: release v9.0.0-rc.2 (release.sh) 2022-11-26 14:20:33 +02:00
metrics.go fix(redisotel): correct metrics.DialHook attrs (#2331) 2022-12-23 20:40:07 +08:00
redisotel_test.go feat: add OpenTelemetry metrics instrumentation 2022-10-12 11:09:41 +03:00
tracing.go feat(redisotel): add code attributes 2022-12-06 11:49:56 +02:00

README.md

OpenTelemetry instrumentation for go-redis

Installation

go get github.com/go-redis/redis/extra/redisotel/v9

Usage

Tracing is enabled by adding a hook:

import (
    "github.com/go-redis/redis/v9"
    "github.com/go-redis/redis/extra/redisotel/v9"
)

rdb := rdb.NewClient(&rdb.Options{...})

rdb.AddHook(redisotel.NewTracingHook())

See example and Monitoring Go Redis Performance and Errors for details.