prysm-pulse/client/txpool/service.go
Raul Jordan 92af8bc351 Rename Entire Project to Repo, Change Import Paths and Readmes (#298)
Former-commit-id: b7b8bbd10777012ae6f7d30eb6b05c3b1c3ec5d3 [formerly 06e1112fa0e1092a7137186d3a386972daa2effe]
Former-commit-id: ff2bc760c9dafb6250f056606eb2cbf96b6afa5b
2018-07-20 16:31:26 -05:00

31 lines
825 B
Go

// Package txpool handles incoming transactions for a sharded Ethereum blockchain.
package txpool
import (
"github.com/ethereum/go-ethereum/event"
"github.com/prysmaticlabs/prysm/client/p2p"
log "github.com/sirupsen/logrus"
)
// TXPool handles a transaction pool for a sharded system.
type TXPool struct {
p2p *p2p.Server
transactionsFeed *event.Feed
}
// NewTXPool creates a new observer instance.
func NewTXPool(p2p *p2p.Server) (*TXPool, error) {
return &TXPool{p2p: p2p, transactionsFeed: new(event.Feed)}, nil
}
// Start the main routine for a shard transaction pool.
func (p *TXPool) Start() {
log.Info("Starting shard txpool service")
}
// Stop the main loop for a transaction pool in the shard network.
func (p *TXPool) Stop() error {
log.Info("Stopping shard txpool service")
return nil
}