multi: add shutdown logs in subservers
This commit adds a simple shutdown to every subserver to assist debugging.
This commit is contained in:
15 files changed
+24
-6
No files matched your search
@@ -137,6 +137,9 @@ func (p *OnionProcessor) Start() error {
|
||||
|
||||
// Stop shutsdown the onion processor's sphinx router.
|
||||
func (p *OnionProcessor) Stop() error {
|
||||
|
||||
log.Info("Onion processor shutting down")
|
||||
|
||||
p.router.Stop()
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -91,6 +91,7 @@ func (h *HtlcNotifier) Start() error {
|
||||
func (h *HtlcNotifier) Stop() error {
|
||||
var err error
|
||||
h.stopped.Do(func() {
|
||||
log.Info("HtlcNotifier shutting down")
|
||||
if err = h.ntfnServer.Stop(); err != nil {
|
||||
log.Warnf("error stopping htlc notifier: %v", err)
|
||||
}
|
||||
|
||||
@@ -1942,7 +1942,7 @@ func (s *Switch) Stop() error {
|
||||
return errors.New("htlc switch already shutdown")
|
||||
}
|
||||
|
||||
log.Infof("HTLC Switch shutting down")
|
||||
log.Info("HTLC Switch shutting down")
|
||||
|
||||
close(s.quit)
|
||||
|
||||
|
||||
Reference in new issue
Block a user