#!/usr/bin/env ksh
# vim: ts=4 sw=4 noet :
#==================================================================================
-# Copyright (c) 2019-2020 Nokia
-# Copyright (c) 2018-2020 AT&T Intellectual Property.
+# Copyright (c) 2019-2021 Nokia
+# Copyright (c) 2018-2021 AT&T Intellectual Property.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
#
function run_sender {
export RMR_RTG_SVC=8990
- ./sender${si} $(( nmsg * nrcvrs )) $delay $max_mtype
+ ./sender $(( nmsg * nrcvrs )) $delay $max_mtype
echo $? >/tmp/PID$$.src # must communicate state back via file b/c asynch
}
port=$(( 4560 + ${1:-0} ))
export RMR_RTG_SVC=$(( 9990 + $1 ))
- ./receiver${si} $nmsg $port
+ ./receiver $nmsg $port
echo $? >/tmp/PID$$.$1.rrc
}
#
function set_rt {
typeset port=4560
- typeset endpoints="localhost:4560"
+ typeset endpoints="127.0.0.1:4560"
for (( i=1; i < ${1:-3}; i++ ))
do
- endpoints="$endpoints,localhost:$((port+i))"
+ endpoints="$endpoints,127.0.0.1:$((port+i))"
done
cat <<endKat >rr.rt
-m) max_mtype=$2; shift;;
-M) force_make=1;;
-n) nmsg=$2; shift;;
- -N) si="";; # build/run NNG binaries
+ -N) ;; # ignored for back compat; nng nolonger supported
-r) nrcvrs=$2; shift;;
- -S) si="_si";; # build/run SI95 binaries
+ -S) ;; # ignored for back compat; only si95 is supported
-v) verbose=1;;
*) echo "unrecognised option: $1"
set_rt $nrcvrs
-if (( rebuild || force_make )) || [[ ! -f ./sender${si} || ! -f ./receiver${si} ]]
+if (( rebuild || force_make )) || [[ ! -f ./sender || ! -f ./receiver ]]
then
if ! make >/dev/null 2>&1
then
- echo "[FAIL] cannot find sender${si} and/or receiver${si} binary, and cannot make them.... humm?"
+ echo "[FAIL] cannot find sender and/or receiver binary, and cannot make them.... humm?"
exit 1
fi
fi