aboutsummaryrefslogtreecommitdiff
path: root/cmd/dendrite-demo-yggdrasil/main.go
diff options
context:
space:
mode:
authorNeil Alexander <neilalexander@users.noreply.github.com>2021-01-26 12:56:20 +0000
committerGitHub <noreply@github.com>2021-01-26 12:56:20 +0000
commit9f443317bc578e1897c7eab9b4911f952f39fdbc (patch)
tree1c758596b56fcf9042c688d9f0204d731dbc216e /cmd/dendrite-demo-yggdrasil/main.go
parent64fb6de6d4f0860cc2b7503cfc36eb743552395b (diff)
Graceful shutdowns (#1734)
* Initial graceful stop * Fix dendritejs * Use process context for outbound federation requests in destination queues * Reduce logging * Fix log level
Diffstat (limited to 'cmd/dendrite-demo-yggdrasil/main.go')
-rw-r--r--cmd/dendrite-demo-yggdrasil/main.go4
1 files changed, 3 insertions, 1 deletions
diff --git a/cmd/dendrite-demo-yggdrasil/main.go b/cmd/dendrite-demo-yggdrasil/main.go
index aea6f7c4..8091298b 100644
--- a/cmd/dendrite-demo-yggdrasil/main.go
+++ b/cmd/dendrite-demo-yggdrasil/main.go
@@ -150,6 +150,7 @@ func main() {
),
}
monolith.AddAllPublicRoutes(
+ base.ProcessContext,
base.PublicClientAPIMux,
base.PublicFederationAPIMux,
base.PublicKeyAPIMux,
@@ -200,5 +201,6 @@ func main() {
}
}()
- select {}
+ // We want to block forever to let the HTTP and HTTPS handler serve the APIs
+ base.WaitForShutdown()
}