mirror of
https://github.com/matrix-org/dendrite.git
synced 2026-01-21 04:53:14 -06:00
Try not to reuse HTTP connections in CI, server shutting down is not
fatal
This commit is contained in:
parent
8b4bf1561b
commit
f4d6704d95
|
|
@ -70,6 +70,7 @@ func main() {
|
||||||
cfg.AppServiceAPI.DisableTLSValidation = true
|
cfg.AppServiceAPI.DisableTLSValidation = true
|
||||||
cfg.ClientAPI.RateLimiting.Enabled = false
|
cfg.ClientAPI.RateLimiting.Enabled = false
|
||||||
cfg.FederationAPI.DisableTLSValidation = false
|
cfg.FederationAPI.DisableTLSValidation = false
|
||||||
|
cfg.FederationAPI.DisableHTTPKeepalives = true
|
||||||
// don't hit matrix.org when running tests!!!
|
// don't hit matrix.org when running tests!!!
|
||||||
cfg.FederationAPI.KeyPerspectives = config.KeyPerspectives{}
|
cfg.FederationAPI.KeyPerspectives = config.KeyPerspectives{}
|
||||||
cfg.MediaAPI.BasePath = config.Path(filepath.Join(*dirPath, "media"))
|
cfg.MediaAPI.BasePath = config.Path(filepath.Join(*dirPath, "media"))
|
||||||
|
|
|
||||||
|
|
@ -77,6 +77,11 @@ func JetStreamConsumer(
|
||||||
// The consumer was deleted so stop.
|
// The consumer was deleted so stop.
|
||||||
return
|
return
|
||||||
} else {
|
} else {
|
||||||
|
// Unfortunately, there's no ErrServerShutdown or similar, so we need to compare the string
|
||||||
|
if err.Error() == "nats: Server Shutdown" {
|
||||||
|
logrus.WithContext(ctx).Warn("nats server shutting down")
|
||||||
|
return
|
||||||
|
}
|
||||||
// Something else went wrong, so we'll panic.
|
// Something else went wrong, so we'll panic.
|
||||||
sentry.CaptureException(err)
|
sentry.CaptureException(err)
|
||||||
logrus.WithContext(ctx).WithField("subject", subj).Fatal(err)
|
logrus.WithContext(ctx).WithField("subject", subj).Fatal(err)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue