summaryrefslogtreecommitdiff
path: root/qpid/java/perftests
diff options
context:
space:
mode:
authorAlex Rudyy <orudyy@apache.org>2014-11-17 18:01:18 +0000
committerAlex Rudyy <orudyy@apache.org>2014-11-17 18:01:18 +0000
commit50f859283f47e6d113ed3501658ed7fe64bd5637 (patch)
treef24f82ee0e7affd5da8dfde21cb696a6f63baa81 /qpid/java/perftests
parent2eff12e5498a2dbcd28e1b95850851c1b88cf8b5 (diff)
downloadqpid-python-50f859283f47e6d113ed3501658ed7fe64bd5637.tar.gz
QPID-6228: [Performance Tests] Add simple tests to measure performance in HA scenarios
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1640198 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/java/perftests')
-rw-r--r--qpid/java/perftests/etc/ha/chardefs/1001-ScalingParticipants.chartdef48
-rw-r--r--qpid/java/perftests/etc/ha/readme.txt33
-rw-r--r--qpid/java/perftests/etc/ha/testdefs/ScalingParticipants.js92
3 files changed, 173 insertions, 0 deletions
diff --git a/qpid/java/perftests/etc/ha/chardefs/1001-ScalingParticipants.chartdef b/qpid/java/perftests/etc/ha/chardefs/1001-ScalingParticipants.chartdef
new file mode 100644
index 0000000000..c1450714a0
--- /dev/null
+++ b/qpid/java/perftests/etc/ha/chardefs/1001-ScalingParticipants.chartdef
@@ -0,0 +1,48 @@
+#
+# 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.
+#
+
+chartType=XYLINE
+chartTitle=Scaling participants in non-HA and HA scenarios
+chartSubtitle=Persistent 1KB messages, transacted
+chartDescription=1,2,5,10 producers/consumers, single queue, persistent, transacted, with message payload 1KB.
+
+xAxisTitle=Participants
+yAxisTitle=Throughput (messages/s)
+
+series.1.statement=SELECT totalNumberOfConsumers, throughputMessagesPerS FROM ScalingParticipants WHERE participantName = 'All'
+series.1.legend=Non HA
+series.1.dir=${csvCurrentDir}
+series.1.colourName=blue
+
+#series.1.statement=SELECT totalNumberOfConsumers, throughputMessagesPerS FROM ScalingParticipants-non-ha WHERE participantName = 'All'
+#series.1.legend=Non HA
+#series.1.dir=${csvCurrentDir}
+#series.1.colourName=blue
+
+#series.2.statement=SELECT totalNumberOfConsumers, throughputMessagesPerS FROM ScalingParticipants-3-node-cluster WHERE participantName = 'All'
+#series.2.legend=3 Nodes Cluster
+#series.2.dir=${csvCurrentDir}
+#series.2.colourName=dark_green
+
+#series.3.statement=SELECT totalNumberOfConsumers, throughputMessagesPerS FROM ScalingParticipants-3-node-cluster-1-node-down WHERE participantName = 'All'
+#series.3.legend=3 Nodes Cluster with one node down
+#series.3.dir=${csvCurrentDir}
+#series.3.colourName=red
+
+
diff --git a/qpid/java/perftests/etc/ha/readme.txt b/qpid/java/perftests/etc/ha/readme.txt
new file mode 100644
index 0000000000..f23793b26c
--- /dev/null
+++ b/qpid/java/perftests/etc/ha/readme.txt
@@ -0,0 +1,33 @@
+#
+# 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.
+#
+
+This folder contains test definitions and chart definitions for the tests measuring throughput on scaling participants.
+They could be useful for testing performance in HA scenarios.
+
+The tests can be executed with:
+
+perfetsts> java -cp './target/*:./target/dependency/*:./etc/' -Dqpid.amqp.version=0-91 -Dqpid.disttest.duration=50000 \
+ -Dqpid.dest_syntax=BURL org.apache.qpid.disttest.ControllerRunner jndi-config=./etc/perftests-jndi.properties \
+ test-config=./etc/ha/testdefs/ScalingParticipants.js distributed=false writeToDb=false
+
+Graphs can be built with:
+
+perfetsts> java -cp './visualisation-jfc/target/dependency/*:./visualisation-jfc/target/*' -Djava.awt.headless=true \
+ -Dlog4j.configuration=file://./etc/log4j.properties -DcsvCurrentDir=. -DcsvBaselineDir=. -DbaselineName=na \
+ org.apache.qpid.disttest.charting.ChartingUtil chart-defs=./etc/ha/1001-ScalingParticipants.chartdef
diff --git a/qpid/java/perftests/etc/ha/testdefs/ScalingParticipants.js b/qpid/java/perftests/etc/ha/testdefs/ScalingParticipants.js
new file mode 100644
index 0000000000..eb092b6fa2
--- /dev/null
+++ b/qpid/java/perftests/etc/ha/testdefs/ScalingParticipants.js
@@ -0,0 +1,92 @@
+/*
+ *
+ * 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.
+ *
+ */
+var jsonObject = { _tests:[] };
+
+var duration = 30000;
+var queueName = "direct://amq.direct//scaling-participants?durable='true'";
+
+var numbersOfParticipants = [1, 2, 5, 10];
+
+for(participantIndex=0; participantIndex < numbersOfParticipants.length; participantIndex++)
+{
+ var participantNumber = numbersOfParticipants[participantIndex];
+ var test = {
+ "_name": "Varying number of participants: " + participantNumber + " consumers - " + participantNumber + " producers - PERSISTENT",
+ "_queues":[
+ {
+ "_name": queueName,
+ "_durable": true
+ }
+ ],
+ "_clients":
+ QPID.times(participantNumber,
+ {
+ "_name": "producingClient__PRODUCING_CLIENT_INDEX",
+ "_connections":[
+ {
+ "_name": "connection1",
+ "_factory": "connectionfactory",
+ "_sessions": [
+ {
+ "_sessionName": "session1",
+ "_acknowledgeMode": 0,
+ "_producers": [
+ {
+ "_name": "Producer__PRODUCING_CLIENT_INDEX",
+ "_destinationName": queueName,
+ "_maximumDuration": duration,
+ "_deliveryMode": 2,
+ "_messageSize": 1024
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "__PRODUCING_CLIENT_INDEX")
+ .concat(QPID.times(participantNumber,
+ {
+ "_name": "consumingClient__CONSUMING_CLIENT_INDEX",
+ "_connections":[
+ {
+ "_name": "connection1",
+ "_factory": "connectionfactory",
+ "_sessions": [
+ {
+ "_sessionName": "session1",
+ "_acknowledgeMode": 0,
+ "_consumers": [
+ {
+ "_name": "Consumer__CONSUMING_CLIENT_INDEX",
+ "_destinationName": queueName,
+ "_maximumDuration": duration
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ "__CONSUMING_CLIENT_INDEX"))
+ };
+ jsonObject._tests= jsonObject._tests.concat(test);
+}