2020-10-05 00:15:27 +00:00
|
|
|
// Package beaconv1 defines a gRPC beacon service implementation,
|
|
|
|
// following the official API standards https://ethereum.github.io/eth2.0-APIs/#/.
|
|
|
|
// This package includes the beacon and config endpoints.
|
|
|
|
package beaconv1
|
|
|
|
|
|
|
|
import (
|
|
|
|
"github.com/prysmaticlabs/prysm/beacon-chain/blockchain"
|
|
|
|
blockfeed "github.com/prysmaticlabs/prysm/beacon-chain/core/feed/block"
|
|
|
|
"github.com/prysmaticlabs/prysm/beacon-chain/db"
|
|
|
|
"github.com/prysmaticlabs/prysm/beacon-chain/operations/attestations"
|
|
|
|
"github.com/prysmaticlabs/prysm/beacon-chain/operations/slashings"
|
2021-02-24 15:29:25 +00:00
|
|
|
"github.com/prysmaticlabs/prysm/beacon-chain/operations/voluntaryexits"
|
2020-10-05 00:15:27 +00:00
|
|
|
"github.com/prysmaticlabs/prysm/beacon-chain/p2p"
|
2021-03-22 15:19:38 +00:00
|
|
|
"github.com/prysmaticlabs/prysm/beacon-chain/rpc/statefetcher"
|
2020-10-05 00:15:27 +00:00
|
|
|
"github.com/prysmaticlabs/prysm/beacon-chain/state/stategen"
|
|
|
|
)
|
|
|
|
|
|
|
|
// Server defines a server implementation of the gRPC Beacon Chain service,
|
2021-06-26 19:00:33 +00:00
|
|
|
// providing RPC endpoints to access data relevant to the Ethereum Beacon Chain.
|
2020-10-05 00:15:27 +00:00
|
|
|
type Server struct {
|
2021-05-20 19:56:53 +00:00
|
|
|
BeaconDB db.ReadOnlyDatabase
|
|
|
|
ChainInfoFetcher blockchain.ChainInfoFetcher
|
|
|
|
GenesisTimeFetcher blockchain.TimeFetcher
|
|
|
|
BlockReceiver blockchain.BlockReceiver
|
|
|
|
BlockNotifier blockfeed.Notifier
|
|
|
|
Broadcaster p2p.Broadcaster
|
|
|
|
AttestationsPool attestations.Pool
|
|
|
|
SlashingsPool slashings.PoolManager
|
|
|
|
VoluntaryExitsPool voluntaryexits.PoolManager
|
|
|
|
StateGenService stategen.StateManager
|
2021-06-15 15:28:49 +00:00
|
|
|
StateFetcher statefetcher.Fetcher
|
2020-10-05 00:15:27 +00:00
|
|
|
}
|