activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject svn commit: r532246 - in /activemq/camel/trunk/camel-core/src: main/java/org/apache/camel/component/queue/QueueEndpointConsumer.java test/java/org/apache/camel/component/pojo/timer/TimerRouteTest.java
Date Wed, 25 Apr 2007 08:14:30 GMT
Author: jstrachan
Date: Wed Apr 25 01:14:29 2007
New Revision: 532246

URL: http://svn.apache.org/viewvc?view=rev&rev=532246
Log:
fixed timing issue in shutdown logic of Queue component along with making the a test case
a little less noisy when ran

Modified:
    activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/component/queue/QueueEndpointConsumer.java
    activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/component/pojo/timer/TimerRouteTest.java

Modified: activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/component/queue/QueueEndpointConsumer.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/component/queue/QueueEndpointConsumer.java?view=diff&rev=532246&r1=532245&r2=532246
==============================================================================
--- activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/component/queue/QueueEndpointConsumer.java
(original)
+++ activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/component/queue/QueueEndpointConsumer.java
Wed Apr 25 01:14:29 2007
@@ -51,7 +51,7 @@
             catch (InterruptedException e) {
                 break;
             }
-            if (exchange != null) {
+            if (exchange != null && !isStopping()) {
                 try {
                     processor.process(exchange);
                 }

Modified: activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/component/pojo/timer/TimerRouteTest.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/component/pojo/timer/TimerRouteTest.java?view=diff&rev=532246&r1=532245&r2=532246
==============================================================================
--- activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/component/pojo/timer/TimerRouteTest.java
(original)
+++ activemq/camel/trunk/camel-core/src/test/java/org/apache/camel/component/pojo/timer/TimerRouteTest.java
Wed Apr 25 01:14:29 2007
@@ -25,11 +25,14 @@
 import org.apache.camel.builder.RouteBuilder;
 import org.apache.camel.component.pojo.PojoComponent;
 import org.apache.camel.impl.DefaultCamelContext;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
 
 /**
  * @version $Revision: 520220 $
  */
 public class TimerRouteTest extends TestCase {
+    private static final transient Log log = LogFactory.getLog(TimerRouteTest.class);
 	
     public void testPojoRoutes() throws Exception {
 
@@ -40,7 +43,7 @@
         PojoComponent component = new PojoComponent();
         component.addService("bar", new Runnable(){
 			public void run() {
-		        System.out.println("hit");
+		        log.debug("hit");
 				hitCount.incrementAndGet();
 			}
         });



Mime
View raw message