2022-01-14 13:08:41 +00:00
|
|
|
package commands
|
|
|
|
|
|
|
|
import (
|
2022-03-17 20:16:02 +00:00
|
|
|
"fmt"
|
2022-06-01 21:47:12 +00:00
|
|
|
|
2022-01-14 13:08:41 +00:00
|
|
|
"github.com/ledgerwatch/erigon/cmd/devnettest/requests"
|
|
|
|
"github.com/spf13/cobra"
|
|
|
|
)
|
|
|
|
|
|
|
|
func init() {
|
|
|
|
rootCmd.AddCommand(txPoolCmd)
|
|
|
|
}
|
|
|
|
|
|
|
|
var txPoolCmd = &cobra.Command{
|
|
|
|
Use: "txpool-content",
|
|
|
|
Short: "Gets content of txpool",
|
|
|
|
Run: func(cmd *cobra.Command, args []string) {
|
2022-05-26 12:08:25 +00:00
|
|
|
showTxPoolContent()
|
2022-01-14 13:08:41 +00:00
|
|
|
},
|
|
|
|
}
|
2022-05-26 12:08:25 +00:00
|
|
|
|
|
|
|
func showTxPoolContent() {
|
|
|
|
if err := requests.TxpoolContent(reqId); err != nil {
|
|
|
|
fmt.Printf("error getting txpool content: %v\n", err)
|
|
|
|
}
|
|
|
|
}
|