Shorten NATS error messages
This commit is contained in:
parent
8766932739
commit
308019b039
2 changed files with 2 additions and 2 deletions
|
@ -110,7 +110,7 @@ func mainLoop(ctx context.Context, wg *sync.WaitGroup, js nats.JetStream, config
|
||||||
_, err = js.Publish(config.NATS.Subject.Event, b)
|
_, err = js.Publish(config.NATS.Subject.Event, b)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
hub.CaptureException(err)
|
hub.CaptureException(err)
|
||||||
log.Printf("Error publishing to NATS: %v", err)
|
log.Print(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
case state := <-ctrl.C:
|
case state := <-ctrl.C:
|
||||||
|
|
|
@ -95,7 +95,7 @@ func publish(subject string, js nats.JetStream, hub *sentry.Hub, reading any) er
|
||||||
_, err = js.Publish(subject, b)
|
_, err = js.Publish(subject, b)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
hub.CaptureException(err)
|
hub.CaptureException(err)
|
||||||
log.Printf("Error publishing to NATS: %v", err)
|
log.Print(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
return err
|
return err
|
||||||
|
|
Loading…
Reference in a new issue