feat: capture logged exceptions and integrate storage-server with sentry

This commit is contained in:
2023-10-19 21:47:09 +02:00
parent efb8ba8b99
commit 1544212ab5
32 changed files with 172 additions and 113 deletions

View File

@ -160,7 +160,7 @@ func RunCommand() *cli.Command {
appCtx := logger.With(cmdCtx, logger.F("address", address))
if err := runApp(appCtx, path, address, documentstoreDSN, blobstoreDSN, shareStoreDSN, accountsFile, appsRepository); err != nil {
logger.Error(appCtx, "could not run app", logger.E(errors.WithStack(err)))
logger.Error(appCtx, "could not run app", logger.CapturedE(errors.WithStack(err)))
}
}(p, port, idx)
}
@ -354,7 +354,7 @@ func findMatchingDeviceAddress(ctx context.Context, from string, defaultAddr str
if err != nil {
logger.Error(
ctx, "could not retrieve iface adresses",
logger.E(errors.WithStack(err)), logger.F("iface", ifa.Name),
logger.CapturedE(errors.WithStack(err)), logger.F("iface", ifa.Name),
)
continue
@ -365,7 +365,7 @@ func findMatchingDeviceAddress(ctx context.Context, from string, defaultAddr str
if err != nil {
logger.Error(
ctx, "could not parse address",
logger.E(errors.WithStack(err)), logger.F("address", addr.String()),
logger.CapturedE(errors.WithStack(err)), logger.F("address", addr.String()),
)
continue