github.com/NVIDIA/aistore@v1.3.23-0.20240517131212-7df6609be51d/deploy/dev/docker/playground/stress_get.sh (about) 1 #!/bin/bash 2 3 if ! [ -x "$(command -v jq)" ]; then 4 echo "Error: jq is not installed." >&2 5 exit 1 6 fi 7 8 OBJECTS=`curl -s -X POST http://172.50.0.2:8080/v1/buckets/$1 -H 'Content-Type: application/json' -d '{"action":"listobjects","value":{"props": "name"}}' | jq -r '.entries[].name'` 9 10 echo "Getting all objects from $1 bucket, each 40 times..." 11 for run in {1..40}; do 12 echo "Batch $run..." 13 for obj in $OBJECTS; do 14 wget -O/dev/null -q http://172.50.0.2:8080/v1/objects/$1/$obj & 15 done 16 17 while test $(jobs -p|wc -w) -ge 500; do sleep 0.01; done 18 done