Skip to content

Commit

Permalink
Remove watch logs step and simplify workflow args
Browse files Browse the repository at this point in the history
  • Loading branch information
ffakenz authored and ch1bo committed Aug 28, 2024
1 parent 36ac132 commit cdf5ff6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 108 deletions.
34 changes: 5 additions & 29 deletions .github/workflows/network-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,6 @@ on:
description: 'Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)'
required: false
default: false
wait_peer_disconnected:
type: boolean
description: 'Check other peers see the target peer is disconnected before running benchmark.'
required: false
default: false
target_peer:
description: 'Select the peer to target with netem package loss'
required: true
type: choice
options:
- alice
- bob
- carol
default: alice

jobs:
network-test:
Expand All @@ -32,6 +18,7 @@ jobs:
# Note: At present we can only run for 3 peers; to configure this for
# more we need to make the docker-compose spin-up dynamic across
# however many we would like to configure here.
# Currently this is just a label and does not have any functional impact.
peers: [3]
scaling_factor: [10, 50]
netem_loss: [0, 1, 2, 3, 4, 5, 10, 20]
Expand Down Expand Up @@ -100,27 +87,14 @@ jobs:
continue-on-error: true
run: |
# Extract inputs with defaults for non-workflow_dispatch events
peers="${{ matrix.peers }}"
percent="${{ matrix.netem_loss }}"
scaling_factor="${{ matrix.scaling_factor }}"
target_peer="${{ github.event.inputs.target_peer || 'alice' }}"
target_peer="alice"
peers_info_json=$(.github/workflows/network/peers_info_json.sh)
.github/workflows/network/run_pumba.sh $target_peer $percent $peers_info_json
wait_peer_disconnected="${{ github.event.inputs.wait_peer_disconnected || false }}"
if [[ "$wait_peer_disconnected" == "true" ]]; then
.github/workflows/network/watch_logs.sh $target_peer $peers_info_json
fi
client_args=""
for i in $(seq 1 $peers); do
port=$((4000 + $i))
client_args+=" --hydra-client=localhost:$port"
done
# Run benchmark on demo
mkdir benchmarks
touch benchmarks/test.log
Expand All @@ -132,7 +106,9 @@ jobs:
--timeout=1000s \
--testnet-magic 42 \
--node-socket=demo/devnet/node.socket \
$client_args
--hydra-client=localhost:4001 \
--hydra-client=localhost:4002 \
--hydra-client=localhost:4003
- name: Acquire logs
if: always()
Expand Down
79 changes: 0 additions & 79 deletions .github/workflows/network/watch_logs.sh

This file was deleted.

0 comments on commit cdf5ff6

Please sign in to comment.