mirror of
https://github.com/fluencelabs/tendermint
synced 2025-07-31 04:01:55 +00:00
Simplify Service/Reactor pattern
This commit is contained in:
@@ -49,15 +49,17 @@ func NewConsensusReactor(consensusState *ConsensusState, blockStore *bc.BlockSto
|
||||
return conR
|
||||
}
|
||||
|
||||
func (conR *ConsensusReactor) AfterStart() {
|
||||
func (conR *ConsensusReactor) OnStart() {
|
||||
log.Notice("ConsensusReactor ", "fastSync", conR.fastSync)
|
||||
conR.BaseReactor.OnStart()
|
||||
if !conR.fastSync {
|
||||
conR.conS.Start()
|
||||
}
|
||||
go conR.broadcastNewRoundStepRoutine()
|
||||
}
|
||||
|
||||
func (conR *ConsensusReactor) AfterStop() {
|
||||
func (conR *ConsensusReactor) OnStop() {
|
||||
conR.BaseReactor.OnStop()
|
||||
conR.conS.Stop()
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user