From 3ecadf5f8705ebf97716c26903d64a2c56c6a130 Mon Sep 17 00:00:00 2001 From: Nelz Date: Tue, 1 Feb 2022 23:26:14 -0800 Subject: [PATCH] chore: instrumentation name and version (#2012) --- extra/redisotel/redisotel.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/extra/redisotel/redisotel.go b/extra/redisotel/redisotel.go index 96ce7a6a..40041c2d 100644 --- a/extra/redisotel/redisotel.go +++ b/extra/redisotel/redisotel.go @@ -14,8 +14,7 @@ import ( ) const ( - // todo: consider using the full module path "github.com/go-redis/redis/extra/redisotel" - defaultTracerName = "github.com/go-redis/redis" + defaultTracerName = "github.com/go-redis/redis/extra/redisotel" ) type TracingHook struct { @@ -32,8 +31,7 @@ func NewTracingHook(opts ...Option) *TracingHook { tracer := cfg.tp.Tracer( defaultTracerName, - // todo: consider adding a version - // trace.WithInstrumentationVersion("semver:8.11.4"), + trace.WithInstrumentationVersion("semver:"+redis.Version()), ) return &TracingHook{tracer: tracer} }