Return-Path: Delivered-To: apmail-activemq-commits-archive@www.apache.org Received: (qmail 98298 invoked from network); 20 Sep 2007 11:09:55 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 20 Sep 2007 11:09:55 -0000 Received: (qmail 33428 invoked by uid 500); 20 Sep 2007 11:09:46 -0000 Delivered-To: apmail-activemq-commits-archive@activemq.apache.org Received: (qmail 33400 invoked by uid 500); 20 Sep 2007 11:09:46 -0000 Mailing-List: contact commits-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list commits@activemq.apache.org Received: (qmail 33391 invoked by uid 99); 20 Sep 2007 11:09:46 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 20 Sep 2007 04:09:46 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO eris.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 20 Sep 2007 11:09:53 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 0B82C1A9832; Thu, 20 Sep 2007 04:09:33 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r577683 - /activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/QueueWorkerPrefetchTest.java Date: Thu, 20 Sep 2007 11:09:32 -0000 To: commits@activemq.apache.org From: rajdavies@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20070920110933.0B82C1A9832@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: rajdavies Date: Thu Sep 20 04:09:32 2007 New Revision: 577683 URL: http://svn.apache.org/viewvc?rev=577683&view=rev Log: Don't use System.out Modified: activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/QueueWorkerPrefetchTest.java Modified: activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/QueueWorkerPrefetchTest.java URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/QueueWorkerPrefetchTest.java?rev=577683&r1=577682&r2=577683&view=diff ============================================================================== --- activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/QueueWorkerPrefetchTest.java (original) +++ activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/QueueWorkerPrefetchTest.java Thu Sep 20 04:09:32 2007 @@ -37,12 +37,15 @@ import org.apache.activemq.ActiveMQConnectionFactory; import org.apache.activemq.ActiveMQPrefetchPolicy; import org.apache.activemq.broker.BrokerService; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; /** * Test case demonstrating situation where messages are not delivered to consumers. */ public class QueueWorkerPrefetchTest extends TestCase implements MessageListener { + private static final Log LOG = LogFactory.getLog(QueueWorkerPrefetchTest.class); private static final int BATCH_SIZE = 10; private static final long WAIT_TIMEOUT = 1000*10; @@ -156,7 +159,7 @@ long acks = acksReceived.incrementAndGet(); latch.get().countDown(); if (acks % 1 == 0) { - System.out.println("Master now has ack count of: " + acksReceived); + LOG.info("Master now has ack count of: " + acksReceived); } } @@ -212,7 +215,7 @@ fail("First batch only received " + acksReceived + " messages"); } - System.out.println("First batch received"); + LOG.info("First batch received"); // Send another message to the work queue, and wait for the next 1000 acks. It is // at this point where the workers never get notified of this message, as they @@ -226,7 +229,7 @@ fail("Second batch only received " + acksReceived + " messages"); } - System.out.println("Second batch received"); + LOG.info("Second batch received"); // Cleanup all JMS resources. for (int i = 0; i < NUM_WORKERS; i++) {