You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by gs...@apache.org on 2009/06/30 12:46:35 UTC
svn commit: r789671 - in /qpid/trunk/qpid/cpp/src/tests: Makefile.am
ring_queue_test run_ring_queue_test
Author: gsim
Date: Tue Jun 30 10:46:35 2009
New Revision: 789671
URL: http://svn.apache.org/viewvc?rev=789671&view=rev
Log:
Add some ring queue tests to make check-long (fix script to use QPID_PORT correctly)
Added:
qpid/trunk/qpid/cpp/src/tests/run_ring_queue_test (with props)
Modified:
qpid/trunk/qpid/cpp/src/tests/Makefile.am
qpid/trunk/qpid/cpp/src/tests/ring_queue_test
Modified: qpid/trunk/qpid/cpp/src/tests/Makefile.am
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/Makefile.am?rev=789671&r1=789670&r2=789671&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/tests/Makefile.am (original)
+++ qpid/trunk/qpid/cpp/src/tests/Makefile.am Tue Jun 30 10:46:35 2009
@@ -271,7 +271,9 @@
TestMessageStore.h \
TxMocks.h \
replication_test \
- run_perftest
+ run_perftest \
+ ring_queue_test \
+ run_ring_queue_test
check_LTLIBRARIES += libdlclose_noop.la
libdlclose_noop_la_LDFLAGS = -module -rpath $(abs_builddir)
@@ -282,7 +284,7 @@
# Longer running stability tests, not run by default check: target.
# Not run under valgrind, too slow
-LONG_TESTS+=start_broker fanout_perftest shared_perftest multiq_perftest topic_perftest run_failover_soak stop_broker \
+LONG_TESTS+=start_broker fanout_perftest shared_perftest multiq_perftest topic_perftest run_ring_queue_test run_failover_soak stop_broker \
reliable_replication_test federated_cluster_test_with_node_failure
EXTRA_DIST+=fanout_perftest shared_perftest multiq_perftest topic_perftest run_failover_soak reliable_replication_test \
Modified: qpid/trunk/qpid/cpp/src/tests/ring_queue_test
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/ring_queue_test?rev=789671&r1=789670&r2=789671&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/tests/ring_queue_test (original)
+++ qpid/trunk/qpid/cpp/src/tests/ring_queue_test Tue Jun 30 10:46:35 2009
@@ -28,12 +28,13 @@
SENDERS=1
RECEIVERS=1
CONCURRENT=0
+BROKER_URL="-a ${QPID_BROKER:-localhost}:${QPID_PORT:-5672}"
setup() {
if [[ $DURABLE -gt 0 ]]; then
EXTRA_ARGS=" --durable"
fi
- qpid-config add queue $QUEUE_NAME --max-queue-count $LIMIT --limit-policy ring $EXTRA_ARGS
+ qpid-config $BROKER_URL add queue $QUEUE_NAME --max-queue-count $LIMIT --limit-policy ring $EXTRA_ARGS
}
send() {
@@ -47,7 +48,7 @@
cleanup() {
rm -f sender_${QUEUE_NAME}_* receiver_${QUEUE_NAME}_*
- qpid-config add queue $QUEUE_NAME
+ qpid-config $BROKER_URL add queue $QUEUE_NAME
}
log() {
@@ -140,7 +141,6 @@
-q <queue> the name of the queue to use
-s <senders> the number of senders to start
-r <receivers> the number of receivers to start
- -u <url>
-l <limit> the limit for the ring queue
-m <messages> the number of messages to send
-c if specified, receivers will run concurrently with senders
@@ -156,7 +156,6 @@
s) SENDERS=$OPTARG ;;
r) RECEIVERS=$OPTARG ;;
m) MESSAGES=$OPTARG ;;
- u) URL=$OPTARG ;;
d) DURABLE=1 ;;
c) CONCURRENT=1 ;;
h) usage;;
Added: qpid/trunk/qpid/cpp/src/tests/run_ring_queue_test
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/tests/run_ring_queue_test?rev=789671&view=auto
==============================================================================
--- qpid/trunk/qpid/cpp/src/tests/run_ring_queue_test (added)
+++ qpid/trunk/qpid/cpp/src/tests/run_ring_queue_test Tue Jun 30 10:46:35 2009
@@ -0,0 +1,37 @@
+#!/bin/bash
+
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+#script to run a sequence of ring queue tests via make
+
+#setup path to find qpid-config and sender/receiver test progs
+srcdir=`dirname $0`
+PYTHON_DIR=$srcdir/../../../python
+export PYTHONPATH=$PYTHON_DIR
+export PATH=./:$PYTHON_DIR/commands:$PATH
+
+#set port to connect to via env var
+test -s qpidd.port && QPID_PORT=`cat qpidd.port`
+export QPID_PORT
+
+ring_queue_test -c -s 4 -r 4
+ring_queue_test -s 4 -r 0
+ring_queue_test -s 1 -r 1
+
+
Propchange: qpid/trunk/qpid/cpp/src/tests/run_ring_queue_test
------------------------------------------------------------------------------
svn:executable = *
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org