Documentation ¶
Index ¶
- type Service
- func (p *Service) BroadcastBatches(batches []*common.ExtBatch) error
- func (p *Service) HealthStatus() host.HealthStatus
- func (p *Service) RefreshPeerList()
- func (p *Service) RequestBatchesFromSequencer(fromSeqNo *big.Int) error
- func (p *Service) RespondToBatchRequest(requestID string, batches []*common.ExtBatch) error
- func (p *Service) SendTxToSequencer(tx common.EncryptedTx) error
- func (p *Service) Start() error
- func (p *Service) Stop() error
- func (p *Service) SubscribeForBatchRequests(handler host.P2PBatchRequestHandler) func()
- func (p *Service) SubscribeForBatches(handler host.P2PBatchHandler) func()
- func (p *Service) SubscribeForTx(handler host.P2PTxHandler) func()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Service ¶ added in v0.14.0
type Service struct {
// contains filtered or unexported fields
}
func NewSocketP2PLayer ¶
func NewSocketP2PLayer(config *config.HostConfig, serviceLocator p2pServiceLocator, logger gethlog.Logger, metricReg gethmetrics.Registry) *Service
NewSocketP2PLayer - returns the Socket implementation of the P2P
func (*Service) BroadcastBatches ¶ added in v0.14.0
func (*Service) HealthStatus ¶ added in v0.14.0
func (p *Service) HealthStatus() host.HealthStatus
func (*Service) RefreshPeerList ¶ added in v0.14.0
func (p *Service) RefreshPeerList()
RefreshPeerList - fetches the latest peer list from L1 and updates the peerAddresses. Note: this is designed to be run in a separate goroutine, it will retry a few times before giving up.
func (*Service) RequestBatchesFromSequencer ¶ added in v0.14.0
func (*Service) RespondToBatchRequest ¶ added in v0.14.0
func (*Service) SendTxToSequencer ¶ added in v0.14.0
func (p *Service) SendTxToSequencer(tx common.EncryptedTx) error
func (*Service) SubscribeForBatchRequests ¶ added in v0.14.0
func (p *Service) SubscribeForBatchRequests(handler host.P2PBatchRequestHandler) func()
func (*Service) SubscribeForBatches ¶ added in v0.14.0
func (p *Service) SubscribeForBatches(handler host.P2PBatchHandler) func()
func (*Service) SubscribeForTx ¶ added in v0.14.0
func (p *Service) SubscribeForTx(handler host.P2PTxHandler) func()
Click to show internal directories.
Click to hide internal directories.