close shuts down the core
()
| 110 | |
| 111 | // close shuts down the core |
| 112 | func (c *core) close() { |
| 113 | if !c.closed { |
| 114 | c.closed = true |
| 115 | close(c.closeChan) |
| 116 | } |
| 117 | |
| 118 | if c.annSub != nil { |
| 119 | err := c.annSub.Unsubscribe() |
| 120 | if err != nil { |
| 121 | c.log.Debug("failed to unsubscribe from proxy announcements", "error", err) |
| 122 | } |
| 123 | } |
| 124 | |
| 125 | c.mbus.Close() |
| 126 | } |
| 127 | |
| 128 | func (c *core) Start() error { |
| 129 | // increment the client reference counter |
no test coverage detected