merge conflict follow up

This commit is contained in:
William Banfield
2021-08-20 13:42:16 -04:00
parent 0bfe698429
commit c7028d111f
5 changed files with 32 additions and 40 deletions
+10 -5
View File
@@ -8,6 +8,7 @@ import (
"github.com/rs/cors"
"github.com/tendermint/tendermint/config"
"github.com/tendermint/tendermint/internal/consensus"
"github.com/tendermint/tendermint/libs/log"
"github.com/tendermint/tendermint/libs/pubsub"
"github.com/tendermint/tendermint/rpc/core"
@@ -28,11 +29,11 @@ type Server struct {
// Routes returns the set of routes used by the Inspect server.
func Routes(cfg config.RPCConfig, s state.Store, bs state.BlockStore, es []indexer.EventSink) core.RoutesMap {
env := &core.Environment{
Config: cfg,
EventSinks: es,
StateStore: s,
BlockStore: bs,
WaitSyncChecker: waitSyncCheckerImpl{},
Config: cfg,
EventSinks: es,
StateStore: s,
BlockStore: bs,
ConsensusReactor: waitSyncCheckerImpl{},
}
return core.RoutesMap{
"blockchain": server.NewRPCFunc(env.BlockchainInfo, "minHeight,maxHeight", true),
@@ -93,6 +94,10 @@ func (_ waitSyncCheckerImpl) WaitSync() bool {
return false
}
func (_ waitSyncCheckerImpl) GetPeerState(peerID types.NodeID) (*consensus.PeerState, bool) {
return nil, false
}
// ListenAndServe listens on the address specified in srv.Addr and handles any
// incoming requests over HTTP using the Inspect rpc handler specified on the server.
func (srv *Server) ListenAndServe(ctx context.Context) error {