redis/extra/redisotel
Bogdan Drutu 67082aad38
Run go mod tidy in redisotel
Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
2021-08-05 10:41:37 -07:00
..
example Update to otel trace v1.0.0-RC1 (stable) and metric v0.21.0 (unstable) (#1802) 2021-06-29 10:23:07 +08:00
README.md extra/redisotel: add readme and example 2021-04-18 14:49:28 +03:00
go.mod Update to otel trace v1.0.0-RC1 (stable) and metric v0.21.0 (unstable) (#1802) 2021-06-29 10:23:07 +08:00
go.sum Run go mod tidy in redisotel 2021-08-05 10:41:37 -07:00
redisotel.go Add constructors 2021-04-16 15:00:10 +03:00

README.md

OpenTelemetry instrumentation for go-redis

Installation

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

Usage

Tracing is enabled by adding a hook:

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

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

rdb.AddHook(redisotel.NewTracingHook())

See example and documentation for more details.