Go-Redis Instrumentation

The Redis instrumentation currently reports all queries in an unsanitized fashion. This means that any Personal Identifiable Information (PII) data those queries contain, like email addresses and passwords, is sent to AppSignal. This will be configurable in a future version of the Redis instrumentation.

For HIPAA-covered entities, more information about signing a Business Associate Agreement (BAA) can be found in our Business Add-Ons documentation.

Setup

To instrument your Go-Redis code, you'll need to import the OpenTelemetry official instrumentation package:

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

After initializing your Redis client, instrument tracing and metrics as in the example below.

Go
rdb := redis.NewClient(&redis.Options{ Addr: "0.0.0.0:6379", }) if err := redisotel.InstrumentTracing(rdb); err != nil { panic(err) }