mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2024-12-22 03:30:37 +00:00
Don't run pos downloader or engine api for bor (#9220)
Pos downloader and the engine api code are not necessary for Bor. This adds code to suppress their start up.
This commit is contained in:
parent
a592cbf163
commit
320fe0ab8b
@ -895,7 +895,9 @@ func (s *Ethereum) Init(stack *node.Node, config *ethconfig.Config) error {
|
||||
chainKv := s.chainDB
|
||||
var err error
|
||||
|
||||
s.sentriesClient.Hd.StartPoSDownloader(s.sentryCtx, s.sentriesClient.SendHeaderRequest, s.sentriesClient.Penalize)
|
||||
if config.Genesis.Config.Bor == nil {
|
||||
s.sentriesClient.Hd.StartPoSDownloader(s.sentryCtx, s.sentriesClient.SendHeaderRequest, s.sentriesClient.Penalize)
|
||||
}
|
||||
|
||||
emptyBadHash := config.BadBlockHash == libcommon.Hash{}
|
||||
if !emptyBadHash {
|
||||
@ -948,7 +950,9 @@ func (s *Ethereum) Init(stack *node.Node, config *ethconfig.Config) error {
|
||||
}()
|
||||
}
|
||||
|
||||
go s.engineBackendRPC.Start(&httpRpcCfg, s.chainDB, s.blockReader, ff, stateCache, s.agg, s.engine, ethRpcClient, txPoolRpcClient, miningRpcClient)
|
||||
if config.Genesis.Config.Bor == nil {
|
||||
go s.engineBackendRPC.Start(&httpRpcCfg, s.chainDB, s.blockReader, ff, stateCache, s.agg, s.engine, ethRpcClient, txPoolRpcClient, miningRpcClient)
|
||||
}
|
||||
|
||||
// Register the backend on the node
|
||||
stack.RegisterLifecycle(s)
|
||||
|
Loading…
Reference in New Issue
Block a user