mirror of
https://github.com/OffchainLabs/prysm.git
synced 2026-01-09 15:37:56 -05:00
added txpool func
Former-commit-id: ce9c444b973f4c856987e3393b76dceb4676bb10 [formerly 89fc90106f425a943ee1c556b0904eff5c96dda4] Former-commit-id: c3a97c1421c394b9aaa15aaecdb2dd7a1aea75a2
This commit is contained in:
@@ -72,8 +72,14 @@ func (c *Client) Start() error {
|
||||
return err
|
||||
}
|
||||
|
||||
// Listens to incoming transactions from the geth node's txpool
|
||||
// TODO: Wait to be selected as a collator, then start listening to the
|
||||
// geth node's txpool.
|
||||
|
||||
// Listens to incoming transactions from the geth node's txpool and directs
|
||||
// them into the VMC if node is a collator
|
||||
if err := listenTXPool(c); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
|
||||
13
sharding/txpool.go
Normal file
13
sharding/txpool.go
Normal file
@@ -0,0 +1,13 @@
|
||||
package sharding
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
)
|
||||
|
||||
// listenTXPool finds the pending tx's from the running geth node
|
||||
// and sorts them by descending order of gas price, eliminates those
|
||||
// that ask for too much gas, and routes them over to the VMC if the current
|
||||
// node is a collator
|
||||
func listenTXPool(c *Client) error {
|
||||
return fmt.Errorf("Not Implemented")
|
||||
}
|
||||
Reference in New Issue
Block a user