Documentation
¶
Index ¶
- func GetIndexedRecentActivity(ctx context.Context, ec *ethclient.Client, c *ethrpc.Client, ...) (*mode.IndexedActivity, error)
- func GetRandomModeEnumValue(deps *mode.Dependencies) config.Mode
- func GetRecallTransactions(ctx context.Context, c *ethclient.Client, rpc *ethrpc.Client, ...) ([]rpctypes.PolyTransaction, error)
- func GetRecentBlocks(ctx context.Context, ec *ethclient.Client, c *ethrpc.Client, ...) ([]*json.RawMessage, error)
- func RawTransactionToNewTx(pt rpctypes.PolyTransaction, nonce uint64, price, tipCap *big.Int) *types.Transaction
- type BlobMode
- func (m *BlobMode) Aliases() []string
- func (m *BlobMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *BlobMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *BlobMode) Name() string
- func (m *BlobMode) RequiresContract() bool
- func (m *BlobMode) RequiresERC20() bool
- func (m *BlobMode) RequiresERC721() bool
- type ContractCallMode
- func (m *ContractCallMode) Aliases() []string
- func (m *ContractCallMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *ContractCallMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *ContractCallMode) Name() string
- func (m *ContractCallMode) RequiresContract() bool
- func (m *ContractCallMode) RequiresERC20() bool
- func (m *ContractCallMode) RequiresERC721() bool
- type DeployMode
- func (m *DeployMode) Aliases() []string
- func (m *DeployMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *DeployMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *DeployMode) Name() string
- func (m *DeployMode) RequiresContract() bool
- func (m *DeployMode) RequiresERC20() bool
- func (m *DeployMode) RequiresERC721() bool
- type ERC20Mode
- func (m *ERC20Mode) Aliases() []string
- func (m *ERC20Mode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *ERC20Mode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *ERC20Mode) Name() string
- func (m *ERC20Mode) RequiresContract() bool
- func (m *ERC20Mode) RequiresERC20() bool
- func (m *ERC20Mode) RequiresERC721() bool
- type ERC721Mode
- func (m *ERC721Mode) Aliases() []string
- func (m *ERC721Mode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *ERC721Mode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *ERC721Mode) Name() string
- func (m *ERC721Mode) RequiresContract() bool
- func (m *ERC721Mode) RequiresERC20() bool
- func (m *ERC721Mode) RequiresERC721() bool
- type IncrementMode
- func (m *IncrementMode) Aliases() []string
- func (m *IncrementMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *IncrementMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *IncrementMode) Name() string
- func (m *IncrementMode) RequiresContract() bool
- func (m *IncrementMode) RequiresERC20() bool
- func (m *IncrementMode) RequiresERC721() bool
- type RPCMode
- func (m *RPCMode) Aliases() []string
- func (m *RPCMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *RPCMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *RPCMode) Name() string
- func (m *RPCMode) RequiresContract() bool
- func (m *RPCMode) RequiresERC20() bool
- func (m *RPCMode) RequiresERC721() bool
- type RandomMode
- func (m *RandomMode) Aliases() []string
- func (m *RandomMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *RandomMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *RandomMode) Name() string
- func (m *RandomMode) RequiresContract() bool
- func (m *RandomMode) RequiresERC20() bool
- func (m *RandomMode) RequiresERC721() bool
- type RecallMode
- func (m *RecallMode) Aliases() []string
- func (m *RecallMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *RecallMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *RecallMode) Name() string
- func (m *RecallMode) RequiresContract() bool
- func (m *RecallMode) RequiresERC20() bool
- func (m *RecallMode) RequiresERC721() bool
- type StoreMode
- func (m *StoreMode) Aliases() []string
- func (m *StoreMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *StoreMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *StoreMode) Name() string
- func (m *StoreMode) RequiresContract() bool
- func (m *StoreMode) RequiresERC20() bool
- func (m *StoreMode) RequiresERC721() bool
- type TransactionMode
- func (m *TransactionMode) Aliases() []string
- func (m *TransactionMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *TransactionMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *TransactionMode) Name() string
- func (m *TransactionMode) RequiresContract() bool
- func (m *TransactionMode) RequiresERC20() bool
- func (m *TransactionMode) RequiresERC721() bool
- type UniswapV3Mode
- func (m *UniswapV3Mode) Aliases() []string
- func (m *UniswapV3Mode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, ...) (start, end time.Time, txHash common.Hash, err error)
- func (m *UniswapV3Mode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
- func (m *UniswapV3Mode) Name() string
- func (m *UniswapV3Mode) RequiresContract() bool
- func (m *UniswapV3Mode) RequiresERC20() bool
- func (m *UniswapV3Mode) RequiresERC721() bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetIndexedRecentActivity ¶
func GetIndexedRecentActivity(ctx context.Context, ec *ethclient.Client, c *ethrpc.Client, recallLength, blockBatchSize uint64) (*mode.IndexedActivity, error)
GetIndexedRecentActivity builds indexed activity data from recent blocks for RPC mode.
func GetRandomModeEnumValue ¶
func GetRandomModeEnumValue(deps *mode.Dependencies) config.Mode
GetRandomModeEnumValue returns a random Mode enum value. Does not include: blob, contract-call, recall, rpc, uniswapv3
func GetRecallTransactions ¶
func GetRecallTransactions(ctx context.Context, c *ethclient.Client, rpc *ethrpc.Client, recallLength, blockBatchSize uint64) ([]rpctypes.PolyTransaction, error)
GetRecallTransactions fetches transactions from recent blocks for replay.
func GetRecentBlocks ¶
func GetRecentBlocks(ctx context.Context, ec *ethclient.Client, c *ethrpc.Client, recallLength, blockBatchSize uint64, onlyTxHashes bool) ([]*json.RawMessage, error)
GetRecentBlocks fetches recent blocks from the chain.
func RawTransactionToNewTx ¶
func RawTransactionToNewTx(pt rpctypes.PolyTransaction, nonce uint64, price, tipCap *big.Int) *types.Transaction
RawTransactionToNewTx converts a PolyTransaction to a new transaction with updated nonce and gas prices.
Types ¶
type BlobMode ¶
type BlobMode struct{}
BlobMode implements blob transaction sending.
func (*BlobMode) RequiresContract ¶
func (*BlobMode) RequiresERC20 ¶
func (*BlobMode) RequiresERC721 ¶
type ContractCallMode ¶
type ContractCallMode struct{}
ContractCallMode implements generic contract calls.
func (*ContractCallMode) Aliases ¶
func (m *ContractCallMode) Aliases() []string
func (*ContractCallMode) Execute ¶
func (m *ContractCallMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, tops *bind.TransactOpts) (start, end time.Time, txHash common.Hash, err error)
func (*ContractCallMode) Init ¶
func (m *ContractCallMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
func (*ContractCallMode) Name ¶
func (m *ContractCallMode) Name() string
func (*ContractCallMode) RequiresContract ¶
func (m *ContractCallMode) RequiresContract() bool
func (*ContractCallMode) RequiresERC20 ¶
func (m *ContractCallMode) RequiresERC20() bool
func (*ContractCallMode) RequiresERC721 ¶
func (m *ContractCallMode) RequiresERC721() bool
type DeployMode ¶
type DeployMode struct{}
DeployMode implements contract deployment.
func (*DeployMode) Aliases ¶
func (m *DeployMode) Aliases() []string
func (*DeployMode) Execute ¶
func (m *DeployMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, tops *bind.TransactOpts) (start, end time.Time, txHash common.Hash, err error)
func (*DeployMode) Init ¶
func (m *DeployMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
func (*DeployMode) Name ¶
func (m *DeployMode) Name() string
func (*DeployMode) RequiresContract ¶
func (m *DeployMode) RequiresContract() bool
func (*DeployMode) RequiresERC20 ¶
func (m *DeployMode) RequiresERC20() bool
func (*DeployMode) RequiresERC721 ¶
func (m *DeployMode) RequiresERC721() bool
type ERC20Mode ¶
type ERC20Mode struct{}
ERC20Mode implements ERC20 token transfers.
func (*ERC20Mode) RequiresContract ¶
func (*ERC20Mode) RequiresERC20 ¶
func (*ERC20Mode) RequiresERC721 ¶
type ERC721Mode ¶
type ERC721Mode struct{}
ERC721Mode implements ERC721 token minting.
func (*ERC721Mode) Aliases ¶
func (m *ERC721Mode) Aliases() []string
func (*ERC721Mode) Execute ¶
func (m *ERC721Mode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, tops *bind.TransactOpts) (start, end time.Time, txHash common.Hash, err error)
func (*ERC721Mode) Init ¶
func (m *ERC721Mode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
func (*ERC721Mode) Name ¶
func (m *ERC721Mode) Name() string
func (*ERC721Mode) RequiresContract ¶
func (m *ERC721Mode) RequiresContract() bool
func (*ERC721Mode) RequiresERC20 ¶
func (m *ERC721Mode) RequiresERC20() bool
func (*ERC721Mode) RequiresERC721 ¶
func (m *ERC721Mode) RequiresERC721() bool
type IncrementMode ¶
type IncrementMode struct{}
IncrementMode implements counter incrementing via LoadTester contract.
func (*IncrementMode) Aliases ¶
func (m *IncrementMode) Aliases() []string
func (*IncrementMode) Execute ¶
func (m *IncrementMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, tops *bind.TransactOpts) (start, end time.Time, txHash common.Hash, err error)
func (*IncrementMode) Init ¶
func (m *IncrementMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
func (*IncrementMode) Name ¶
func (m *IncrementMode) Name() string
func (*IncrementMode) RequiresContract ¶
func (m *IncrementMode) RequiresContract() bool
func (*IncrementMode) RequiresERC20 ¶
func (m *IncrementMode) RequiresERC20() bool
func (*IncrementMode) RequiresERC721 ¶
func (m *IncrementMode) RequiresERC721() bool
type RPCMode ¶
type RPCMode struct{}
RPCMode implements random RPC method calls.
func (*RPCMode) RequiresContract ¶
func (*RPCMode) RequiresERC20 ¶
func (*RPCMode) RequiresERC721 ¶
type RandomMode ¶
type RandomMode struct {
// contains filtered or unexported fields
}
RandomMode implements randomly selecting from other modes.
func (*RandomMode) Aliases ¶
func (m *RandomMode) Aliases() []string
func (*RandomMode) Execute ¶
func (m *RandomMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, tops *bind.TransactOpts) (start, end time.Time, txHash common.Hash, err error)
func (*RandomMode) Init ¶
func (m *RandomMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
func (*RandomMode) Name ¶
func (m *RandomMode) Name() string
func (*RandomMode) RequiresContract ¶
func (m *RandomMode) RequiresContract() bool
func (*RandomMode) RequiresERC20 ¶
func (m *RandomMode) RequiresERC20() bool
func (*RandomMode) RequiresERC721 ¶
func (m *RandomMode) RequiresERC721() bool
type RecallMode ¶
type RecallMode struct{}
RecallMode implements replaying historical transactions.
func (*RecallMode) Aliases ¶
func (m *RecallMode) Aliases() []string
func (*RecallMode) Execute ¶
func (m *RecallMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, tops *bind.TransactOpts) (start, end time.Time, txHash common.Hash, err error)
func (*RecallMode) Init ¶
func (m *RecallMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
func (*RecallMode) Name ¶
func (m *RecallMode) Name() string
func (*RecallMode) RequiresContract ¶
func (m *RecallMode) RequiresContract() bool
func (*RecallMode) RequiresERC20 ¶
func (m *RecallMode) RequiresERC20() bool
func (*RecallMode) RequiresERC721 ¶
func (m *RecallMode) RequiresERC721() bool
type StoreMode ¶
type StoreMode struct{}
StoreMode implements storing bytes in the LoadTester contract.
func (*StoreMode) RequiresContract ¶
func (*StoreMode) RequiresERC20 ¶
func (*StoreMode) RequiresERC721 ¶
type TransactionMode ¶
type TransactionMode struct{}
TransactionMode implements basic ETH transfer transactions.
func (*TransactionMode) Aliases ¶
func (m *TransactionMode) Aliases() []string
func (*TransactionMode) Execute ¶
func (m *TransactionMode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, tops *bind.TransactOpts) (start, end time.Time, txHash common.Hash, err error)
func (*TransactionMode) Init ¶
func (m *TransactionMode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
func (*TransactionMode) Name ¶
func (m *TransactionMode) Name() string
func (*TransactionMode) RequiresContract ¶
func (m *TransactionMode) RequiresContract() bool
func (*TransactionMode) RequiresERC20 ¶
func (m *TransactionMode) RequiresERC20() bool
func (*TransactionMode) RequiresERC721 ¶
func (m *TransactionMode) RequiresERC721() bool
type UniswapV3Mode ¶
type UniswapV3Mode struct{}
UniswapV3Mode implements UniswapV3 swap operations.
func (*UniswapV3Mode) Aliases ¶
func (m *UniswapV3Mode) Aliases() []string
func (*UniswapV3Mode) Execute ¶
func (m *UniswapV3Mode) Execute(ctx context.Context, cfg *config.Config, deps *mode.Dependencies, tops *bind.TransactOpts) (start, end time.Time, txHash common.Hash, err error)
func (*UniswapV3Mode) Init ¶
func (m *UniswapV3Mode) Init(ctx context.Context, cfg *config.Config, deps *mode.Dependencies) error
func (*UniswapV3Mode) Name ¶
func (m *UniswapV3Mode) Name() string
func (*UniswapV3Mode) RequiresContract ¶
func (m *UniswapV3Mode) RequiresContract() bool
func (*UniswapV3Mode) RequiresERC20 ¶
func (m *UniswapV3Mode) RequiresERC20() bool
func (*UniswapV3Mode) RequiresERC721 ¶
func (m *UniswapV3Mode) RequiresERC721() bool