node: move handshake out of constructor (#8264)

This commit is contained in:
Sam Kleinman
2022-04-07 11:21:10 -04:00
committed by GitHub
parent 681cdf8347
commit 6ed3f2d98d
4 changed files with 81 additions and 69 deletions

View File

@@ -95,8 +95,7 @@ func initDBs(
return blockStore, stateDB, makeCloser(closers), nil
}
func createAndStartIndexerService(
ctx context.Context,
func createIndexerService(
cfg *config.Config,
dbProvider config.DBProvider,
eventBus *eventbus.EventBus,
@@ -116,10 +115,6 @@ func createAndStartIndexerService(
Metrics: metrics,
})
if err := indexerService.Start(ctx); err != nil {
return nil, nil, err
}
return indexerService, eventSinks, nil
}
@@ -264,6 +259,7 @@ func createConsensusReactor(
evidencePool,
eventBus,
consensus.StateMetrics(csMetrics),
consensus.SkipStateStoreBootstrap,
)
if err != nil {
return nil, nil, err