mirror of
https://github.com/VinGarcia/ksql.git
synced 2025-09-04 19:36:56 +00:00
Updated Debugging with ksql.InjectLogger
(markdown)
parent
d1d9838cd5
commit
73c924e975
@ -8,7 +8,7 @@ You can either decide to use one of the two built-in loggers, by using:
|
|||||||
Or you can create your own, by passing a custom function to InjectLogger, e.g.:
|
Or you can create your own, by passing a custom function to InjectLogger, e.g.:
|
||||||
|
|
||||||
```golang
|
```golang
|
||||||
ctx := InjectLogger(ctx, func(ctx context.Context, values LogValues) {
|
ctx := ksql.InjectLogger(ctx, func(ctx context.Context, values LogValues) {
|
||||||
fmt.Println("the values are:", values.Query, values.Params, values.Err)
|
fmt.Println("the values are:", values.Query, values.Params, values.Err)
|
||||||
})
|
})
|
||||||
```
|
```
|
||||||
|
Loading…
x
Reference in New Issue
Block a user