Files
dbis_core/scripts/load-test-as4.sh
2026-03-02 12:14:07 -08:00

31 lines
694 B
Bash
Executable File

#!/bin/bash
# AS4 Settlement Load Testing Script
# Basic load test using curl
set -e
BASE_URL="${AS4_BASE_URL:-http://localhost:3000}"
CONCURRENT="${AS4_LOAD_CONCURRENT:-10}"
REQUESTS="${AS4_LOAD_REQUESTS:-100}"
echo "========================================="
echo "AS4 Settlement Load Test"
echo "========================================="
echo "Base URL: $BASE_URL"
echo "Concurrent: $CONCURRENT"
echo "Total Requests: $REQUESTS"
echo ""
# Test health endpoint
echo "Testing health endpoint..."
time for i in $(seq 1 $REQUESTS); do
curl -s "$BASE_URL/health" > /dev/null &
if [ $((i % $CONCURRENT)) -eq 0 ]; then
wait
fi
done
wait
echo ""
echo "Load test complete!"