As flagged in #1525, the Raftstore shutdown is never triggered.
Store.Close() is not called anywhere. It should be called in main.go.
- It should also takes a
context.Context argument to be passed down to the consensus instance.
Consensus.Stop() ignored the context argument and builds its own instead.
- It also attempts its own cleanup with
defer c.Stop(context.Background()). Removing this should allow the removal of the once.
As flagged in #1525, the Raftstore shutdown is never triggered.
Store.Close()is not called anywhere. It should be called inmain.go.context.Contextargument to be passed down to the consensus instance.Consensus.Stop()ignored thecontextargument and builds its own instead.defer c.Stop(context.Background()). Removing this should allow the removal of theonce.