handle clean shutdown

This commit is contained in:
Jesse de Wit
2023-01-23 14:54:55 +01:00
parent 294080b067
commit 5aad6b313e
6 changed files with 26 additions and 4 deletions

View File

@@ -66,6 +66,10 @@ func (c *ClnPlugin) Start() {
c.setupLogging()
go c.listenRequests()
<-c.done
s := c.server
if s != nil {
<-s.completed
}
}
// Stops the cln plugin. Drops any remaining work immediately.