Skip to content

Commit

Permalink
add gnosis profiles
Browse files Browse the repository at this point in the history
  • Loading branch information
erwin-wee committed Jun 20, 2024
1 parent 2edbd56 commit 4f6f71a
Show file tree
Hide file tree
Showing 2 changed files with 63 additions and 0 deletions.
32 changes: 32 additions & 0 deletions chainbench/profile/gnosis/archive.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
"""
Gnosis Archive profile.
"""

from locust import constant_pacing

from chainbench.user.protocol.evm import EvmUser


class GnosisArchiveProfile(EvmUser):
wait_time = constant_pacing(1)
rpc_calls = {
EvmUser.eth_block_number: 284,
EvmUser.eth_call: 218,
EvmUser.eth_get_block_by_number: 120,
EvmUser.eth_syncing: 81,
EvmUser.net_peer_count: 79,
EvmUser.eth_get_transaction_receipt: 47,
EvmUser.eth_get_logs: 26,
EvmUser.eth_chain_id: 15,
EvmUser.eth_get_code: 6,
EvmUser.web3_client_version: 5,
EvmUser.eth_fee_history: 5,
EvmUser.eth_get_transaction_count: 2,
EvmUser.eth_get_balance: 2,
EvmUser.eth_get_block_by_hash: 2,
EvmUser.eth_gas_price: 2,
EvmUser.eth_estimate_gas: 1,
EvmUser.eth_get_transaction_by_hash: 1,
}

tasks = EvmUser.expand_tasks(rpc_calls)
31 changes: 31 additions & 0 deletions chainbench/profile/gnosis/general.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
"""
Gnosis profile.
"""

from locust import constant_pacing

from chainbench.user.protocol.evm import EvmUser


class GnosisProfile(EvmUser):
wait_time = constant_pacing(1)
rpc_calls = {
EvmUser.eth_get_transaction_receipt: 1128,
EvmUser.eth_get_transaction_by_hash: 439,
EvmUser.eth_gas_price: 431,
EvmUser.eth_get_transaction_count: 431,
EvmUser.eth_get_balance: 429,
EvmUser.eth_call: 322,
EvmUser.eth_get_block_by_number: 315,
EvmUser.eth_estimate_gas: 287,
EvmUser.eth_get_code: 285,
EvmUser.debug_trace_block_by_number: 191,
EvmUser.net_version: 129,
EvmUser.eth_get_logs: 28,
EvmUser.eth_chain_id: 19,
EvmUser.eth_block_number: 10,
EvmUser.eth_max_priority_fee_per_gas: 1,
EvmUser.eth_get_block_by_hash: 1,
}

tasks = EvmUser.expand_tasks(rpc_calls)

0 comments on commit 4f6f71a

Please sign in to comment.