feat: add Sentry setup

This commit is contained in:
2022-12-16 16:02:16 +01:00
parent 577ad601ca
commit b8a8783838
3 changed files with 19 additions and 7 deletions
+2 -2
View File
@@ -129,7 +129,7 @@ func start(closeEvents chan error, logger *log.Entry, connectToAmqpFunc func(url
goamqp.EventStreamPublisher(eventPublisher),
goamqp.TransientEventStreamConsumer("SubGraph.Updated", serviceCache.Update, domain.SubGraphUpdated{}),
}
if err := conn.Start(setups...); err != nil {
if err := conn.Start(rootCtx, setups...); err != nil {
return fmt.Errorf("failed to setup AMQP: %v", err)
}
@@ -260,6 +260,6 @@ func ConnectAMQP(url string) (Connection, error) {
}
type Connection interface {
Start(opts ...goamqp.Setup) error
Start(ctx context.Context, opts ...goamqp.Setup) error
Close() error
}