aligned_layer icon indicating copy to clipboard operation
aligned_layer copied to clipboard

feat(testing): Task Sender / Stress Tester

Open PatStiles opened this issue 1 year ago • 0 comments

Changes Adds a cli program to:

  • Generate, fund wallets, and deposit to aligned payment service
  • Send proofs with a burst of n infinitely from the generated wallets.
  • Open n connection and hang infinitely.

Testing Before anything make sure you are running a localtestnet.

Generate and fund wallets

NUM_WALLETS=10 AMOUNT_TO_DEPOSIT=0.1 AMOUNT_TO_DEPOSIT_TO_ALIGNED=0.099  make task_sender_generate_and_fund_wallets_devnet

This will generate a file with the private keys of the funded wallets by default this is in: scripts/test_files/task_sender/wallets/funded_wallets.devnet. You'll then provide the path when sending infinite proofs.

A rich anvil account is passed by default, in holesky for example, you'll need to provide the FUNDING_WALLET_PRIVATE_KEY .

Generate groth16 proofs

NUMBER_PROOFS=`x` make task_sender_generate_groth16_proofs 

This will create a proofs folder in scripts/test_files/task_sender/proofs by default.

Send infinite proofs Before running this command, you need to make sure you have first generated wallets and proofs. This command reads the default paths mentioned before.

make task_sender_infinite_proofs_devnet 

Test connections This will start m connections and hang them infinitely without sending any proof

NUM_SENDERS=`m` make task_sender_test_connections_devnet

Closes #1113 and Closes #1015. Reopens #1162 due to merge conflicts.

PatStiles avatar Oct 07 '24 19:10 PatStiles