mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2024-12-25 04:57:17 +00:00
remove emed of rpcdaemon (not ready)
This commit is contained in:
parent
7566e1dbbe
commit
ae652ad5c9
@ -48,14 +48,11 @@ import (
|
|||||||
"github.com/ledgerwatch/erigon-lib/txpool/txpooluitl"
|
"github.com/ledgerwatch/erigon-lib/txpool/txpooluitl"
|
||||||
"github.com/ledgerwatch/erigon/cmd/downloader/downloader"
|
"github.com/ledgerwatch/erigon/cmd/downloader/downloader"
|
||||||
"github.com/ledgerwatch/erigon/cmd/downloader/downloadergrpc"
|
"github.com/ledgerwatch/erigon/cmd/downloader/downloadergrpc"
|
||||||
"github.com/ledgerwatch/erigon/cmd/rpcdaemon/cli"
|
|
||||||
"github.com/ledgerwatch/erigon/cmd/rpcdaemon/commands"
|
|
||||||
"github.com/ledgerwatch/erigon/cmd/rpcdaemon/interfaces"
|
"github.com/ledgerwatch/erigon/cmd/rpcdaemon/interfaces"
|
||||||
"github.com/ledgerwatch/erigon/cmd/sentry/sentry"
|
"github.com/ledgerwatch/erigon/cmd/sentry/sentry"
|
||||||
"github.com/ledgerwatch/erigon/common"
|
"github.com/ledgerwatch/erigon/common"
|
||||||
"github.com/ledgerwatch/erigon/common/debug"
|
"github.com/ledgerwatch/erigon/common/debug"
|
||||||
"github.com/ledgerwatch/erigon/consensus"
|
"github.com/ledgerwatch/erigon/consensus"
|
||||||
"github.com/ledgerwatch/erigon/consensus/bor"
|
|
||||||
"github.com/ledgerwatch/erigon/consensus/clique"
|
"github.com/ledgerwatch/erigon/consensus/clique"
|
||||||
"github.com/ledgerwatch/erigon/consensus/ethash"
|
"github.com/ledgerwatch/erigon/consensus/ethash"
|
||||||
"github.com/ledgerwatch/erigon/consensus/parlia"
|
"github.com/ledgerwatch/erigon/consensus/parlia"
|
||||||
@ -527,30 +524,32 @@ func New(stack *node.Node, config *ethconfig.Config, txpoolCfg txpool2.Config, l
|
|||||||
}
|
}
|
||||||
//eth.APIBackend.gpo = gasprice.NewOracle(eth.APIBackend, gpoParams)
|
//eth.APIBackend.gpo = gasprice.NewOracle(eth.APIBackend, gpoParams)
|
||||||
|
|
||||||
// start HTTP API
|
/*
|
||||||
httpRpcCfg := cli.Flags{} // TODO: add rpcdaemon cli flags to Erigon and fill this struct (or break it to smaller config objects)
|
// start HTTP API
|
||||||
ethRpcClient, txPoolRpcClient, miningRpcClient, starkNetRpcClient, stateCache, ff, err := cli.EmbeddedServices(
|
httpRpcCfg := cli.Flags{} // TODO: add rpcdaemon cli flags to Erigon and fill this struct (or break it to smaller config objects)
|
||||||
ctx, chainKv, httpRpcCfg.StateCache, blockReader,
|
ethRpcClient, txPoolRpcClient, miningRpcClient, starkNetRpcClient, stateCache, ff, err := cli.EmbeddedServices(
|
||||||
ethBackendRPC,
|
ctx, chainKv, httpRpcCfg.StateCache, blockReader,
|
||||||
backend.txPool2GrpcServer,
|
ethBackendRPC,
|
||||||
miningRPC,
|
backend.txPool2GrpcServer,
|
||||||
)
|
miningRPC,
|
||||||
if err != nil {
|
)
|
||||||
return nil, err
|
if err != nil {
|
||||||
}
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
var borDb kv.RoDB
|
var borDb kv.RoDB
|
||||||
if casted, ok := backend.engine.(*bor.Bor); ok {
|
if casted, ok := backend.engine.(*bor.Bor); ok {
|
||||||
borDb = casted.DB
|
borDb = casted.DB
|
||||||
}
|
}
|
||||||
apiList := commands.APIList(chainKv, borDb, ethRpcClient, txPoolRpcClient, miningRpcClient, starkNetRpcClient, ff, stateCache, blockReader, httpRpcCfg, nil)
|
apiList := commands.APIList(chainKv, borDb, ethRpcClient, txPoolRpcClient, miningRpcClient, starkNetRpcClient, ff, stateCache, blockReader, httpRpcCfg, nil)
|
||||||
go func() {
|
go func() {
|
||||||
_ = apiList
|
_ = apiList
|
||||||
//if err := cli.StartRpcServer(ctx, httpRpcCfg, apiList); err != nil {
|
//if err := cli.StartRpcServer(ctx, httpRpcCfg, apiList); err != nil {
|
||||||
// log.Error(err.Error())
|
// log.Error(err.Error())
|
||||||
// return
|
// return
|
||||||
//}
|
//}
|
||||||
}()
|
}()
|
||||||
|
*/
|
||||||
|
|
||||||
// Register the backend on the node
|
// Register the backend on the node
|
||||||
stack.RegisterAPIs(backend.APIs())
|
stack.RegisterAPIs(backend.APIs())
|
||||||
|
Loading…
Reference in New Issue
Block a user