mirror of
https://github.com/logos-messaging/logos-messaging-interop-tests.git
synced 2026-01-05 23:43:07 +00:00
Adding store scripts
This commit is contained in:
parent
2fd56d4aa3
commit
9f56e44996
109
scripts/Lite_protocol_scripts/store/store_15nodes_scenario1.sh
Normal file
109
scripts/Lite_protocol_scripts/store/store_15nodes_scenario1.sh
Normal file
@ -0,0 +1,109 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
# This implements a waku-simulator with 15 nodes network, 1 service, 1 edge node added
|
||||||
|
# service node is limited to 1 cpu core with only 512 MB
|
||||||
|
# Runs different test phases with different load from sonda (STORE) side
|
||||||
|
# 1. 2 sonda instances, query every 500ms
|
||||||
|
# 2. 5 sonda instances, query every 200ms
|
||||||
|
# 3. 10 sonda instances, query every 100ms
|
||||||
|
|
||||||
|
echo "Running test..."
|
||||||
|
|
||||||
|
current_time=$(date +"%Y-%m-%d %H:%M:%S")
|
||||||
|
echo "Bringing up simulator at $current_time"
|
||||||
|
|
||||||
|
cd ./waku-simulator
|
||||||
|
|
||||||
|
# simulator exports
|
||||||
|
export NUM_NWAKU_NODES=15
|
||||||
|
export TRAFFIC_DELAY_SECONDS=15
|
||||||
|
export MSG_SIZE_KBYTES=10
|
||||||
|
|
||||||
|
docker compose up -d
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
echo "Waiting 30s for service node to be ready..."
|
||||||
|
sleep 30
|
||||||
|
|
||||||
|
cd ./sonda
|
||||||
|
|
||||||
|
# build sonda image
|
||||||
|
docker build -t local-perf-sonda -f Dockerfile.sonda .
|
||||||
|
|
||||||
|
# 2 sondas 500ms
|
||||||
|
|
||||||
|
cat <<EOF > perf-test.env
|
||||||
|
RELAY_NODE_REST_ADDRESS=http://127.0.0.1:8645
|
||||||
|
STORE_NODE_REST_ADDRESS=http://127.0.0.1:8644
|
||||||
|
QUERY_DELAY=0.5
|
||||||
|
STORE_NODES=/ip4/127.0.0.1/tcp/60001/p2p/<SERVICE_PEER_ID>
|
||||||
|
CLUSTER_ID=66
|
||||||
|
SHARD=0
|
||||||
|
HEALTH_THRESHOLD=0.95
|
||||||
|
EOF
|
||||||
|
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
|
||||||
|
echo "Phase 1 running 300s..."
|
||||||
|
sleep 300
|
||||||
|
docker kill $(docker ps -q -f "label=sonda") >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
#5 sondas 200ms
|
||||||
|
|
||||||
|
cat <<EOF > perf-test.env
|
||||||
|
RELAY_NODE_REST_ADDRESS=http://127.0.0.1:8645
|
||||||
|
STORE_NODE_REST_ADDRESS=http://127.0.0.1:8644
|
||||||
|
QUERY_DELAY=0.2
|
||||||
|
STORE_NODES=/ip4/127.0.0.1/tcp/60001/p2p/<SERVICE_PEER_ID>
|
||||||
|
CLUSTER_ID=66
|
||||||
|
SHARD=0
|
||||||
|
HEALTH_THRESHOLD=0.95
|
||||||
|
EOF
|
||||||
|
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
|
||||||
|
echo "Phase 2 running 300s..."
|
||||||
|
sleep 300
|
||||||
|
docker kill $(docker ps -q -f "label=sonda") >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
#10 sondas 100ms
|
||||||
|
cat <<EOF > perf-test.env
|
||||||
|
RELAY_NODE_REST_ADDRESS=http://127.0.0.1:8645
|
||||||
|
STORE_NODE_REST_ADDRESS=http://127.0.0.1:8644
|
||||||
|
QUERY_DELAY=0.1
|
||||||
|
STORE_NODES=/ip4/127.0.0.1/tcp/60001/p2p/<SERVICE_PEER_ID>
|
||||||
|
CLUSTER_ID=66
|
||||||
|
SHARD=0
|
||||||
|
HEALTH_THRESHOLD=0.95
|
||||||
|
EOF
|
||||||
|
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
|
||||||
|
echo "Phase 3 running 300s..."
|
||||||
|
sleep 300
|
||||||
|
docker kill $(docker ps -q -f "label=sonda") >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
cd ./waku-simulator
|
||||||
|
docker compose down
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
current_time=$(date +"%Y-%m-%d %H:%M:%S")
|
||||||
|
echo "Test finished at $current_time"
|
||||||
@ -0,0 +1,59 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
echo "Running test..."
|
||||||
|
|
||||||
|
# This implements a short version of 1st store scenario.
|
||||||
|
# waku-simulator with 15 nodes network, 1 service, 1 edge node added
|
||||||
|
# service node is limited to 1 cpu core with only 512 MB
|
||||||
|
# Runs 1 phase with sonda load:
|
||||||
|
# 1. 10 sonda instances, each queries in every 100ms
|
||||||
|
|
||||||
|
cd ./waku-simulator
|
||||||
|
|
||||||
|
export NUM_NWAKU_NODES=15
|
||||||
|
export TRAFFIC_DELAY_SECONDS=10
|
||||||
|
export MSG_SIZE_KBYTES=8
|
||||||
|
|
||||||
|
docker compose up -d
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
echo "Waiting 20s for service node..."
|
||||||
|
sleep 20
|
||||||
|
|
||||||
|
cd ./sonda
|
||||||
|
|
||||||
|
docker build -t local-perf-sonda -f Dockerfile.sonda .
|
||||||
|
|
||||||
|
cat <<EOF > perf-test.env
|
||||||
|
RELAY_NODE_REST_ADDRESS=http://127.0.0.1:8645
|
||||||
|
STORE_NODE_REST_ADDRESS=http://127.0.0.1:8644
|
||||||
|
QUERY_DELAY=0.1
|
||||||
|
STORE_NODES=/ip4/127.0.0.1/tcp/60001/p2p/<SERVICE_PEER_ID>
|
||||||
|
CLUSTER_ID=66
|
||||||
|
SHARD=0
|
||||||
|
HEALTH_THRESHOLD=0.95
|
||||||
|
EOF
|
||||||
|
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
|
||||||
|
echo "Phase running 300s..."
|
||||||
|
sleep 300
|
||||||
|
|
||||||
|
docker kill $(docker ps -q -f "label=sonda") >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
cd ./waku-simulator
|
||||||
|
docker compose down
|
||||||
|
cd ..
|
||||||
@ -0,0 +1,182 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
|
||||||
|
# waku-simulator with 15 nodes network, 1 service, 1 edge node added
|
||||||
|
# service node is limited to 1 cpu core with only 512 MB
|
||||||
|
# This scenario intended to stress test service node STORE queries with high request frequency
|
||||||
|
# Increasing number of sonda instances and decreasing query delay ms
|
||||||
|
# 16 sondas 100ms
|
||||||
|
# 16 sondas 50ms
|
||||||
|
# 24 sondas 50ms
|
||||||
|
# 24 sondas 20ms
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
echo "Running test..."
|
||||||
|
|
||||||
|
cd ./waku-simulator
|
||||||
|
|
||||||
|
export NUM_NWAKU_NODES=15
|
||||||
|
export TRAFFIC_DELAY_SECONDS=10
|
||||||
|
export MSG_SIZE_KBYTES=12
|
||||||
|
|
||||||
|
docker compose up -d
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
echo "Waiting 30s for service node..."
|
||||||
|
sleep 30
|
||||||
|
|
||||||
|
cd ./sonda
|
||||||
|
|
||||||
|
docker build -t local-perf-sonda -f Dockerfile.sonda .
|
||||||
|
|
||||||
|
#16 sondas 100ms
|
||||||
|
cat <<EOF > perf-test.env
|
||||||
|
RELAY_NODE_REST_ADDRESS=http://127.0.0.1:8645
|
||||||
|
STORE_NODE_REST_ADDRESS=http://127.0.0.1:8644
|
||||||
|
QUERY_DELAY=0.1
|
||||||
|
STORE_NODES=/ip4/127.0.0.1/tcp/60001/p2p/<SERVICE_PEER_ID>
|
||||||
|
CLUSTER_ID=66
|
||||||
|
SHARD=0
|
||||||
|
HEALTH_THRESHOLD=0.95
|
||||||
|
EOF
|
||||||
|
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
|
||||||
|
echo "Phase 1 300s..."
|
||||||
|
sleep 300
|
||||||
|
docker kill $(docker ps -q -f "label=sonda") >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
# 16 sondas 50ms
|
||||||
|
cat <<EOF > perf-test.env
|
||||||
|
RELAY_NODE_REST_ADDRESS=http://127.0.0.1:8645
|
||||||
|
STORE_NODE_REST_ADDRESS=http://127.0.0.1:8644
|
||||||
|
QUERY_DELAY=0.05
|
||||||
|
STORE_NODES=/ip4/127.0.0.1/tcp/60001/p2p/<SERVICE_PEER_ID>
|
||||||
|
CLUSTER_ID=66
|
||||||
|
SHARD=0
|
||||||
|
HEALTH_THRESHOLD=0.95
|
||||||
|
EOF
|
||||||
|
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
|
||||||
|
echo "Phase 2 300s..."
|
||||||
|
sleep 300
|
||||||
|
docker kill $(docker ps -q -f "label=sonda") >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
# 24 sondas 50ms
|
||||||
|
cat <<EOF > perf-test.env
|
||||||
|
RELAY_NODE_REST_ADDRESS=http://127.0.0.1:8645
|
||||||
|
STORE_NODE_REST_ADDRESS=http://127.0.0.1:8644
|
||||||
|
QUERY_DELAY=0.05
|
||||||
|
STORE_NODES=/ip4/127.0.0.1/tcp/60001/p2p/<SERVICE_PEER_ID>
|
||||||
|
CLUSTER_ID=66
|
||||||
|
SHARD=0
|
||||||
|
HEALTH_THRESHOLD=0.95
|
||||||
|
EOF
|
||||||
|
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
|
||||||
|
echo "Phase 3 300s..."
|
||||||
|
sleep 300
|
||||||
|
docker kill $(docker ps -q -f "label=sonda") >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
#24 sondas 20ms
|
||||||
|
cat <<EOF > perf-test.env
|
||||||
|
RELAY_NODE_REST_ADDRESS=http://127.0.0.1:8645
|
||||||
|
STORE_NODE_REST_ADDRESS=http://127.0.0.1:8644
|
||||||
|
QUERY_DELAY=0.02
|
||||||
|
STORE_NODES=/ip4/127.0.0.1/tcp/60001/p2p/<SERVICE_PEER_ID>
|
||||||
|
CLUSTER_ID=66
|
||||||
|
SHARD=0
|
||||||
|
HEALTH_THRESHOLD=0.95
|
||||||
|
EOF
|
||||||
|
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
# repeat 23 more times
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
docker run --env-file ./perf-test.env -l sonda -d --network host local-perf-sonda
|
||||||
|
|
||||||
|
echo "Phase 4 300s..."
|
||||||
|
sleep 300
|
||||||
|
docker kill $(docker ps -q -f "label=sonda") >/dev/null 2>&1 || true
|
||||||
|
|
||||||
|
cd ..
|
||||||
|
|
||||||
|
cd ./waku-simulator
|
||||||
|
docker compose down
|
||||||
|
cd ..
|
||||||
Loading…
x
Reference in New Issue
Block a user