This the code repository for paper "InTime: Towards Performance Predictability In Byzantine Fault Tolerant Proof-of-Stake Consensus" in SIGMOD'25.
-
intime/data/blocks.csvcontains the Ethereum blocks from blockNumber 19000000 to 19000100. -
intime/data/receipts.csvcontains the 18,484 transaction receipts correspondingly.
Both real datasets are extracted using Ethereum ETL.
-
Running environment: Centos 7, Python 3.8
-
Requirements:
intime/requirements.txt
-
intime/main.pycontains all test cases for experiments. -
intime/agnostic.pycontains algorithms for agnostic mean estimation. -
intime/outlier.pycontains algorithms for outlier removal, parameter estimation. -
intime/receipt.pycontains codes for real data (data/blocks.csv,data/receipts.csv) processing. -
intime/draw.pycontains codes for experimental figure ploting.
After installing required packages, directly run python main.py to execute all exeperiments.
We set up a private PoS Ethereum devnet among geo-distributed nodes. We use Geth as the Ethereum client, and Prysm as the consensus client.
intime-devnet/data/txncontains 18,484 transactions in Ethereum blocks from blockNumber 19000000 to 19000100.
-
Running environment: Ubuntu 24.04 LTS, Python 3.9, Docker 27.3.1
-
Requirements:
intime-devnet/requirements.txt
-
intime-devnet/config.yamlcontains the configuration for Prysm. -
intime-devnet/genesis.jsonis the genesis file for the Ethereum chain. -
intime-devnet/docker-compose.yamlis the docker compose file for running a single node with Prysm and Geth.
-
intime-devnet/run_devnet.shis the script to run the devnet on a local machine. -
intime-devnet/start_remote.shis the script to run a global devnet among multiple physical machines, it will set up a bootnode first and then start the rest nodes to form the devnet. -
intime-devnet/clean.shis the script to clean the devnet on a local machine. -
intime-devnet/intime/intime.pyruns the intime instance that (1) records the arrival tiem for listened transactions; (2) when receiving a new block, broadcast the corresponding time vector to other nodes; (3) the judge node collects the time vectors from all nodes and estimates the arrival time for each transaction. -
intime-devnet/intime/compress.pycontains the code for the compression algorithm and experiments. -
intime-devnet/intime/attest_size.pycontains the code to fetch real attestations and compute sizes. -
intime-devnet/intime/send_txn.pysends transactions from the real dataset to the devnet and records the throughput and latency.
-
Setup servers and clone the repo to every server.
- IPs of servers should be stored in
intime-devnet/ip_list.json, and correspondingly set the BOOT_HOST, REMOTE_HOSTS, JUDGE_HOST inintime-devnet/start_remote.sh. - SSH settings like user name and path to ssh keys connecting other servers (REMOTE_USER, KEY_PATH, KEY_LOCAL_PATH) should also be updated in
intime-devnet/start_remote.sh.
- IPs of servers should be stored in
-
Run
IF_INTIME=<if_intime> ALL_NUM_NODES=<all_num_nodes> OPERATION="run_devnet" bash start_remote.shto start the devnet, where-
if_intimeis a boolean value indicating whether to run intime on top of the devnet; -
all_num_nodesis the total number of nodes in the devnet.
-
-
Run
python send_txn.py <all_num_nodes>-<if_intime>to send transactions to the devnet and record the throughput and latency.
Here are instructions to promptly reproduce fig a-j in a single machine.
# run experiments for fig a-h
cd intime
python main.py
# run experiments for fig i-j
cd ../intime-devnet/intime
python compress.py
# plot fig a-j
cd ../../intime
python draw.py