Sha256: a4daab94dc12ecf74153d834cff4ed8cabe4a3eae179413bd25c403e7168ff1c

Contents?: true

Size: 1.73 KB

Versions: 1

Compression:

Stored size: 1.73 KB

Contents

#! /bin/sh

timestamp_postfix=$(date +%Y_%m_%d_%H%M%S)
test_label=query_bench_$timestamp_postfix

if [ $# -gt 0 ] ; then
    test_label=$1
fi
server='default'
if [ $# -gt 1 ] ; then
    server=$2
fi

clients[0]=ec2-50-17-151-136.compute-1.amazonaws.com
clients[1]=ec2-107-22-43-25.compute-1.amazonaws.com
clients[2]=ec2-75-101-174-0.compute-1.amazonaws.com
clients[3]=ec2-50-16-87-55.compute-1.amazonaws.com
clients[4]=ec2-107-22-48-222.compute-1.amazonaws.com
clients[5]=ec2-107-22-61-93.compute-1.amazonaws.com
clients[6]=ec2-107-22-53-145.compute-1.amazonaws.com
clients[7]=ec2-50-17-152-123.compute-1.amazonaws.com
clients[8]=ec2-50-17-155-181.compute-1.amazonaws.com
clients[9]=ec2-75-101-225-80.compute-1.amazonaws.com

n_iterations=100
current_path=`pwd`

# setup the benchmark directory structure
ruby ../prepare_bench "$test_label" query_bench_$timestamp_postfix "1 2 3 5 10"

# simulate variaous number of data records
for n_clients in 1 2 3 5 10
do
	for payload in 1 5 10 50 100 250 500
	do
		result_filename=./bench_results/query_bench_$timestamp_postfix/raw_data/query_bench_result.$payload
		sync_key=sync_${timestamp_postfix}
		for ((  i = 0 ;  i < $n_clients;  i++  ))
		do
			ssh -i /tmp/EC2-inst.pem -o "UserKnownHostsFile /dev/null" -o "StrictHostKeyChecking no" ec2-user@${clients[$i]} "cd /opt/rhoconnect/bench/distr_bench; ./run_distr_client.sh $sync_key $server $n_iterations $payload 1>/dev/null" &
		done
	
		# start main script
		ruby distr_bench_main ${sync_key}_$payload $payload $n_clients $result_filename $server
		sleep 5
	done
done

# once benchmark is finished - process the results
ruby ../lib/bench/bench_result_processor.rb ./bench_results/query_bench_$timestamp_postfix/raw_data ./bench_results/query_bench_$timestamp_postfix/images

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
rhoconnect-3.0.6 bench/distr_bench/run_test_query_script.sh