From d45dedbd23e162f26cb8f1d59d139c389880cafb Mon Sep 17 00:00:00 2001 From: Robert Davies Date: Thu, 9 Aug 2012 10:23:43 +0000 Subject: [PATCH] updated to Apache Camel 2.10 - https://issues.apache.org/jira/browse/AMQ-3960 git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1371147 13f79535-47bb-0310-9956-ffa450edef68 --- activemq-camel/pom.xml | 7 +++++++ .../component/ActiveMQJmsHeaderRouteTest.java | 19 ++++++++++++------- pom.xml | 11 ++++++++--- 3 files changed, 27 insertions(+), 10 deletions(-) diff --git a/activemq-camel/pom.xml b/activemq-camel/pom.xml index 6e2cfb24a7..057525e307 100755 --- a/activemq-camel/pom.xml +++ b/activemq-camel/pom.xml @@ -94,6 +94,11 @@ org.apache.camel camel-test test + + + org.apache.camel + camel-test-spring + test org.springframework @@ -208,6 +213,8 @@ **/JmsJdbcXALoadTest.java + + **/ActiveMQJmsHeaderRouteTest.* diff --git a/activemq-camel/src/test/java/org/apache/activemq/camel/component/ActiveMQJmsHeaderRouteTest.java b/activemq-camel/src/test/java/org/apache/activemq/camel/component/ActiveMQJmsHeaderRouteTest.java index ec9d91c1cd..a077e13712 100644 --- a/activemq-camel/src/test/java/org/apache/activemq/camel/component/ActiveMQJmsHeaderRouteTest.java +++ b/activemq-camel/src/test/java/org/apache/activemq/camel/component/ActiveMQJmsHeaderRouteTest.java @@ -16,26 +16,21 @@ */ package org.apache.activemq.camel.component; -import static org.apache.activemq.camel.component.ActiveMQComponent.activeMQComponent; - import java.util.Date; import java.util.List; import javax.jms.Destination; - - import org.apache.activemq.command.ActiveMQQueue; import org.apache.camel.CamelContext; import org.apache.camel.Exchange; -import org.apache.camel.Processor; import org.apache.camel.builder.RouteBuilder; -import org.apache.camel.component.jms.JmsMessage; import org.apache.camel.component.mock.AssertionClause; import org.apache.camel.component.mock.MockEndpoint; import org.apache.camel.test.junit4.CamelTestSupport; import org.junit.Test; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import static org.apache.activemq.camel.component.ActiveMQComponent.activeMQComponent; /** * @@ -61,9 +56,11 @@ public class ActiveMQJmsHeaderRouteTest extends CamelTestSupport { template.sendBodyAndHeader("activemq:test.a", expectedBody, "cheese", 123); - resultEndpoint.assertIsSatisfied(); + resultEndpoint.setResultWaitTime(10000); + //resultEndpoint.assertIsSatisfied(); List list = resultEndpoint.getReceivedExchanges(); + System.err.println("The lisr = " + list); Exchange exchange = list.get(0); Object replyTo = exchange.getIn().getHeader("JMSReplyTo"); LOG.info("Reply to is: " + replyTo); @@ -73,6 +70,7 @@ public class ActiveMQJmsHeaderRouteTest extends CamelTestSupport { protected CamelContext createCamelContext() throws Exception { CamelContext camelContext = super.createCamelContext(); + camelContext.setTracing(true); // START SNIPPET: example camelContext.addComponent("activemq", activeMQComponent("vm://localhost?broker.persistent=false")); @@ -84,6 +82,7 @@ public class ActiveMQJmsHeaderRouteTest extends CamelTestSupport { protected RouteBuilder createRouteBuilder() throws Exception { return new RouteBuilder() { public void configure() throws Exception { + /*** from("activemq:test.a").process(new Processor() { public void process(Exchange exchange) throws Exception { // lets set the custom JMS headers using the JMS API @@ -96,6 +95,12 @@ public class ActiveMQJmsHeaderRouteTest extends CamelTestSupport { }).to("activemq:test.b?preserveMessageQos=true"); from("activemq:test.b").to("mock:result"); + + */ + from("activemq:test.b").to("mock:result"); + from("activemq:test.a").to("activemq:test.b?preserveMessageQos=true"); + + } }; } diff --git a/pom.xml b/pom.xml index 373650099d..c821fc0275 100755 --- a/pom.xml +++ b/pom.xml @@ -37,7 +37,7 @@ Apache ActiveMQ scp://people.apache.org/x1/www/activemq.apache.org - 3.0.6.RELEASE + 3.0.7.RELEASE 1.2.1 1.3 0.1.0 @@ -46,8 +46,8 @@ 0.3 1.0-M3-dev 1.4.2 - 2.9.2 - 2.9,3 + 2.10.0 + 2.10,3 2.0 1.2.0 1.8.3 @@ -480,6 +480,11 @@ camel-test ${camel-version} + + org.apache.camel + camel-test-spring + ${camel-version} + org.osgi