Skip to content

Commit

Permalink
fix(redisotel): fix the situation of reporting spans multiple times
Browse files Browse the repository at this point in the history
  • Loading branch information
flc1125 committed Oct 23, 2024
1 parent cc9bcb0 commit cc4810c
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions extra/redisotel/tracing.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@ func InstrumentTracing(rdb redis.UniversalClient, opts ...TracingOption) error {
rdb.AddHook(newTracingHook(connString, opts...))
return nil
case *redis.ClusterClient:
rdb.AddHook(newTracingHook("", opts...))

rdb.OnNewNode(func(rdb *redis.Client) {
opt := rdb.Options()
opts = addServerAttributes(opts, opt.Addr)
Expand All @@ -40,8 +38,6 @@ func InstrumentTracing(rdb redis.UniversalClient, opts ...TracingOption) error {
})
return nil
case *redis.Ring:
rdb.AddHook(newTracingHook("", opts...))

rdb.OnNewNode(func(rdb *redis.Client) {
opt := rdb.Options()
opts = addServerAttributes(opts, opt.Addr)
Expand Down

0 comments on commit cc4810c

Please sign in to comment.