From db022ba27e62289a931a7f80b04a8a6128a94733 Mon Sep 17 00:00:00 2001 From: Robert Greig Date: Fri, 6 Apr 2007 15:21:19 +0000 Subject: Added some ramping up performance tests. git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/branches/M2@526194 13f79535-47bb-0310-9956-ffa450edef68 --- .../main/java/org/apache/qpid/requestreply/PingPongProducer.java | 8 ++++---- .../src/test/java/org/apache/qpid/ping/PingAsyncTestPerf.java | 7 ++++--- 2 files changed, 8 insertions(+), 7 deletions(-) (limited to 'java/perftests/src') diff --git a/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java b/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java index f0556eaac1..ce0181558f 100644 --- a/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java +++ b/java/perftests/src/main/java/org/apache/qpid/requestreply/PingPongProducer.java @@ -959,16 +959,16 @@ public class PingPongProducer implements Runnable, MessageListener, ExceptionLis committed = false; // Re-timestamp the message. - message.setLongProperty(MESSAGE_TIMESTAMP_PROPNAME, System.nanoTime()); + // message.setLongProperty(MESSAGE_TIMESTAMP_PROPNAME, System.nanoTime()); // Send the message, passing in the message count. committed = sendMessage(i, message); // Spew out per message timings on every message sonly in verbose mode. - if (_verbose) + /*if (_verbose) { log.info(timestampFormatter.format(new Date()) + ": Pinged at with correlation id, " + messageCorrelationId); - } + }*/ } // Call commit if the send loop finished before reaching a batch size boundary so there may still be uncommitted messages. @@ -1007,7 +1007,7 @@ public class PingPongProducer implements Runnable, MessageListener, ExceptionLis _failBeforeSend = false; } - log.trace("Failing Before Send"); + // log.trace("Failing Before Send"); waitForUser(KILL_BROKER_PROMPT); } diff --git a/java/perftests/src/test/java/org/apache/qpid/ping/PingAsyncTestPerf.java b/java/perftests/src/test/java/org/apache/qpid/ping/PingAsyncTestPerf.java index 9c24ea0379..6c7f22c19a 100644 --- a/java/perftests/src/test/java/org/apache/qpid/ping/PingAsyncTestPerf.java +++ b/java/perftests/src/test/java/org/apache/qpid/ping/PingAsyncTestPerf.java @@ -133,12 +133,13 @@ public class PingAsyncTestPerf extends PingTestPerf implements TimingControllerA */ public void testAsyncPingOk(int numPings) throws Exception { - _logger.debug("public void testAsyncPingOk(int numPings): called"); + // _logger.debug("public void testAsyncPingOk(int numPings): called"); // Ensure that at least one ping was requeusted. if (numPings == 0) { _logger.error("Number of pings requested was zero."); + fail("Number of pings requested was zero."); } // Get the per thread test setup to run the test through. @@ -147,8 +148,8 @@ public class PingAsyncTestPerf extends PingTestPerf implements TimingControllerA // Advance the correlation id of messages to send, to make it unique for this run. perThreadSetup._correlationId = Long.toString(corellationIdGenerator.incrementAndGet()); - String messageCorrelationId = perThreadSetup._correlationId; - _logger.debug("messageCorrelationId = " + messageCorrelationId); + // String messageCorrelationId = perThreadSetup._correlationId; + // _logger.debug("messageCorrelationId = " + messageCorrelationId); // Initialize the count and timing controller for the new correlation id. PerCorrelationId perCorrelationId = new PerCorrelationId(); -- cgit v1.2.1