We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b026cf8 commit 53b3fd3Copy full SHA for 53b3fd3
.github/wordlist.txt
@@ -29,6 +29,7 @@ Lua
29
MSSQL
30
namespace
31
NoSQL
32
+OpenTelemetry
33
ORM
34
Packagist
35
PhpRedis
README.md
@@ -167,6 +167,24 @@ func ExampleClient() *redis.Client {
167
168
```
169
170
+### Instrument with OpenTelemetry
171
+
172
+```go
173
+import (
174
+ "github.com/redis/go-redis/v9"
175
+ "github.com/redis/go-redis/extra/redisotel/v9"
176
+ "errors"
177
+)
178
179
+func main() {
180
+ ...
181
+ rdb := redis.NewClient(&redis.Options{...})
182
183
+ if err := errors.Join(redisotel.InstrumentTracing(rdb), redisotel.InstrumentMetrics(rdb)); err != nil {
184
+ log.Fatal(err)
185
+ }
186
+```
187
188
189
### Advanced Configuration
190
0 commit comments