mirror of
https://github.com/pomerium/pomerium.git
synced 2025-08-03 00:40:25 +02:00
new tracing system
This commit is contained in:
parent
b87d940d11
commit
a6f43f3c3c
127 changed files with 7509 additions and 1454 deletions
|
@ -9,6 +9,7 @@ import (
|
|||
"time"
|
||||
|
||||
"github.com/rs/zerolog"
|
||||
"go.opentelemetry.io/otel/trace"
|
||||
|
||||
"github.com/pomerium/pomerium/internal/log"
|
||||
)
|
||||
|
@ -47,7 +48,10 @@ restart:
|
|||
backoff:
|
||||
for {
|
||||
interval := backoff.NextBackOff()
|
||||
log.Ctx(ctx).Info().Msgf("backing off for %s...", interval.String())
|
||||
span := trace.SpanFromContext(ctx)
|
||||
msg := fmt.Sprintf("backing off for %s...", interval.String())
|
||||
span.AddEvent(msg)
|
||||
log.Ctx(ctx).Info().Msg(msg)
|
||||
timer := time.NewTimer(interval)
|
||||
s := makeSelect(ctx, watches, name, timer.C, fn)
|
||||
next, err := s.Exec(ctx)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue