-
Notifications
You must be signed in to change notification settings - Fork 7
/
Makefile
75 lines (63 loc) · 2.43 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
# This Makefile is a sort of crib sheet for running the load generator.
reset-chain:
rm -rf _agstate/agoric-servers
git checkout -- _agstate/agoric-servers
agoric install
# the 'agoric start local-chain' setup code does not currently provide the
# BLD/RUN necessary to run our loadgen tasks, so we can't use these yet:
run-chain-not-working-yet:
SLOGFILE=$(PWD)/chain.slog agoric start local-chain --verbose
run-client-not-working-yet:
CLIENTSLOGFILE=$(PWD)/client.slog agoric start local-solo 8000
# Use "agoric start -v local-solo 8000" to get solo delivery messages and
# solo vat console.log messages. Or instead use console.eror from within
# vats.
# instead, we must use the Makefile in packages/cosmic-swingset, and the
# "scenario2" rules, which *do* provide the necessary tokens during
# provisioning
CSDIR=/missing/replace/me/packages/cosmic-swingset
run-chain-setup:
$(MAKE) -C $(CSDIR) scenario2-setup
run-chain:
SLOGFILE=$(PWD)/chain.slog $(MAKE) -C $(CSDIR) scenario2-run-chain
run-client:
$(MAKE) -C $(CSDIR) scenario2-run-client
build-docker:
docker build -t loadgen-runner .
daily-perf:
cd results && ../scripts/run-daily-perf.sh
run-loadgen:
yarn loadgen
check:
curl -s http://127.0.0.1:3352/config
light:
curl -s -X PUT --data '{"faucet": { "interval": 60 }}' http://127.0.0.1:3352/config
moderate:
curl -s -X PUT --data '{"faucet": { "interval": 5, "limit": 8}}' http://127.0.0.1:3352/config
heavy:
curl -s -X PUT --data '{"faucet": { "interval": 0.1, "limit": 10}}' http://127.0.0.1:3352/config
none:
curl -s -X PUT --data '{}' http://127.0.0.1:3352/config
amm-moderate:
curl -s -X PUT --data '{"amm": { "interval": 30}}' http://127.0.0.1:3352/config
vault-moderate:
curl -s -X PUT --data '{"vault": { "interval": 30}}' http://127.0.0.1:3352/config
alternating:
curl -s -X PUT --data '{"vault": { "interval": 120}, "amm": { "wait": 60, "interval": 120 }}' http://127.0.0.1:3352/config
# recommended sequence:
# shell 1:
# cd agoric-sdk && yarn && yarn build && make -C packages/cosmic-swingset
# cd testnet-load-generator
# make reset-chain
# make run-chain
# (wait ~60s until "block-manager: block 1 commit")
# shell 2:
# tail -F chain.slog
# shell 3:
# make run-client
# (wait ~120s until "Deployed Wallet!" and the ~4 "gas estimate" lines stop appearing)
# shell 4:
# make run-loadgen
# (wait ~30s until "faucet ready for cycles" appears)
# shell 5:
# make check, or light|moderate|heavy|none to control rate