diff options
author | Kim van der Riet <kpvdr@apache.org> | 2013-02-28 16:14:30 +0000 |
---|---|---|
committer | Kim van der Riet <kpvdr@apache.org> | 2013-02-28 16:14:30 +0000 |
commit | 9c73ef7a5ac10acd6a50d5d52bd721fc2faa5919 (patch) | |
tree | 2a890e1df09e5b896a9b4168a7b22648f559a1f2 /cpp/src/tests/sasl_fed_ex | |
parent | 172d9b2a16cfb817bbe632d050acba7e31401cd2 (diff) | |
download | qpid-python-asyncstore.tar.gz |
Update from trunk r1375509 through r1450773asyncstore
git-svn-id: https://svn.apache.org/repos/asf/qpid/branches/asyncstore@1451244 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/tests/sasl_fed_ex')
-rwxr-xr-x | cpp/src/tests/sasl_fed_ex | 92 |
1 files changed, 11 insertions, 81 deletions
diff --git a/cpp/src/tests/sasl_fed_ex b/cpp/src/tests/sasl_fed_ex index cc5b310067..4ea61c5a2a 100755 --- a/cpp/src/tests/sasl_fed_ex +++ b/cpp/src/tests/sasl_fed_ex @@ -34,17 +34,11 @@ then echo # These are the four different ways of creating links ( or routes+links ) # that the qpid-route command provides. - echo "Usage: ${script_name} dynamic|link|queue|route [cluster]" + echo "Usage: ${script_name} dynamic|link|queue|route" echo exit 1 fi -# Has the user told us to do clustering ? ----------- -clustering_flag= -if [ $# -eq "2" ] && [ "$2" == "cluster" ]; then - clustering_flag=true -fi - qpid_route_method=$1 # Debugging print. -------------------------- @@ -128,15 +122,7 @@ DST_TCP_PORT=5807 SRC_TCP_PORT_2=5802 DST_TCP_PORT_2=5803 -CLUSTER_NAME_SUFFIX=`hostname | tr '.' ' ' | awk '{print $1}'` -CLUSTER_1_NAME=sasl_fed_ex_cluster_1_${CLUSTER_NAME_SUFFIX} -CLUSTER_2_NAME=sasl_fed_ex_cluster_2_${CLUSTER_NAME_SUFFIX} - -print "CLUSTER_1_NAME == ${CLUSTER_1_NAME}" -print "CLUSTER_2_NAME == ${CLUSTER_2_NAME}" - SSL_LIB=${moduledir}/ssl.so -CLUSTER_LIB=${moduledir}/cluster.so export QPID_SSL_CERT_NAME=${TEST_HOSTNAME} @@ -183,80 +169,26 @@ COMMON_BROKER_OPTIONS=" \ function start_brokers { - if [ $1 ]; then - # clustered ---------------------------------------- - print "Starting SRC cluster" - - print " src broker 1" - $QPIDD_EXEC \ - --port=${SRC_TCP_PORT} \ - --ssl-port ${SRC_SSL_PORT} \ - ${COMMON_BROKER_OPTIONS} \ - --load-module ${CLUSTER_LIB} \ - --cluster-name ${CLUSTER_1_NAME} \ - --log-to-file $tmp_root/qpidd_src.log 2> /dev/null - - broker_ports[0]=${SRC_TCP_PORT} - - print " src broker 2" - $QPIDD_EXEC \ - --port=${SRC_TCP_PORT_2} \ - --ssl-port ${SRC_SSL_PORT_2} \ - ${COMMON_BROKER_OPTIONS} \ - --load-module ${CLUSTER_LIB} \ - --cluster-name ${CLUSTER_1_NAME} \ - --log-to-file $tmp_root/qpidd_src_2.log 2> /dev/null - - broker_ports[1]=${SRC_TCP_PORT_2} - - - print "Starting DST cluster" - - print " dst broker 1" - $QPIDD_EXEC \ - --port=${DST_TCP_PORT} \ - --ssl-port ${DST_SSL_PORT} \ - ${COMMON_BROKER_OPTIONS} \ - --load-module ${CLUSTER_LIB} \ - --cluster-name ${CLUSTER_2_NAME} \ - --log-to-file $tmp_root/qpidd_dst.log 2> /dev/null - - broker_ports[2]=${DST_TCP_PORT} - - print " dst broker 2" - $QPIDD_EXEC \ - --port=${DST_TCP_PORT_2} \ - --ssl-port ${DST_SSL_PORT_2} \ - ${COMMON_BROKER_OPTIONS} \ - --load-module ${CLUSTER_LIB} \ - --cluster-name ${CLUSTER_2_NAME} \ - --log-to-file $tmp_root/qpidd_dst_2.log 2> /dev/null - - broker_ports[3]=${DST_TCP_PORT_2} - - else # vanilla brokers -------------------------------- print "Starting SRC broker" $QPIDD_EXEC \ - --port=${SRC_TCP_PORT} \ - --ssl-port ${SRC_SSL_PORT} \ - ${COMMON_BROKER_OPTIONS} \ - --log-to-file $tmp_root/qpidd_src.log 2> /dev/null + --port=${SRC_TCP_PORT} \ + --ssl-port ${SRC_SSL_PORT} \ + ${COMMON_BROKER_OPTIONS} \ + --log-to-file $tmp_root/qpidd_src.log 2> /dev/null broker_ports[0]=${SRC_TCP_PORT} print "Starting DST broker" $QPIDD_EXEC \ - --port=${DST_TCP_PORT} \ - --ssl-port ${DST_SSL_PORT} \ - ${COMMON_BROKER_OPTIONS} \ - --log-to-file $tmp_root/qpidd_dst.log 2> /dev/null + --port=${DST_TCP_PORT} \ + --ssl-port ${DST_SSL_PORT} \ + ${COMMON_BROKER_OPTIONS} \ + --log-to-file $tmp_root/qpidd_dst.log 2> /dev/null broker_ports[1]=${DST_TCP_PORT} - fi } - function halt_brokers { n_brokers=${#broker_ports[@]} print "Halting ${n_brokers} brokers." @@ -270,7 +202,7 @@ function halt_brokers { } -start_brokers $clustering_flag +start_brokers # I am not randomizing these names, because this test creates its own brokers. @@ -329,9 +261,7 @@ fi # to avoid false negatives. sleep 5 -# This should work the same whether or not we are running a clustered test. -# In the case of clustered tests, the status is not printed by qpid_route. -# So in either case, I will look only at the transport field, which should be "ssl". +# Look only at the transport field, which should be "ssl". print "check the link" link_status=$($QPID_ROUTE_EXEC link list localhost:${DST_TCP_PORT} | tail -1 | awk '{print $3}') |