Re: concurrentConsumers issue

2010-11-29 Thread Claus Ibsen
camel-jms uses Spring JMS under the covers. So the concurrent consumers works the way it does in Spring JMS. On Mon, Nov 29, 2010 at 11:41 PM, khein wrote: > > I'm seeing an issue with concurrent consumption of JMS messages.  I've > written a simple test which demonstrates what is occurring.  It

concurrentConsumers issue

2010-11-29 Thread khein
I'm seeing an issue with concurrent consumption of JMS messages. I've written a simple test which demonstrates what is occurring. It seems that threads are NOT being assigned to waiting consumers as they become free, they are being assigned based on the order they were originally called in. Sim

Re: Unit Testing Route

2010-11-29 Thread Claus Ibsen
On Mon, Nov 29, 2010 at 7:01 PM, Claus Straube wrote: > > Hi, > > you can do this by intercepting your routes. > > public void testFoo() throws Exception { >  RouteDefinition route = context.getRouteDefinitions().get("routeId"); > route.adviceWith(context, new RouteBuilder() { >   public void conf

Re: Unit Testing Route

2010-11-29 Thread Claus Straube
Hi, you can do this by intercepting your routes. public void testFoo() throws Exception { RouteDefinition route = context.getRouteDefinitions().get("routeId"); route.adviceWith(context, new RouteBuilder() { public void configure() throws Exception { interceptSendToEndpoint("seda:in")

Re: Question on VM Endpoint, multipleConsumers and OSGi

2010-11-29 Thread Claus Ibsen
On Mon, Nov 29, 2010 at 3:20 PM, klausb wrote: > > Ok, but should it work? Is my assumption correct? The VM wasn't really meant for osgi. It was for sharing messages between WAR files deployed in Apache Tomcat etc. In OSGi there are OSGi services and/or the NMR component for sharing messages betw

Unit Testing Route

2010-11-29 Thread Olivier.Roger
Hello Camel, I am using Camel for some time now and I was wondering how I could perform unit test using the same camel context used in production but still being able to test intermediate messages of the routes. For instance, with the simple routes A --> B and B --> C. At the moment I use 4 prop

Re: [Aggregator] Persistence ?

2010-11-29 Thread Olivier.Roger
Claus, I don't exactly see how to reuse the code already present in Camel. I'm not sure, but from what I saw the HawtDB aggregator uses the transaction manager from HawtDB. In our use cases, using an XA Transaction Manager option. However, I was thinking to use Spring TransactionTemplate with

Re: ActiveMQ String messages get dropped?

2010-11-29 Thread Claus Ibsen
Read about limitations and JMS properties http://camel.apache.org/jms The JMS spec is a bit rigid what and how can be send as JMS properties. On Mon, Nov 29, 2010 at 5:54 PM, Jakub Moskal wrote: > Hi, > > I just started using Camel because apparently this is the way to go if > I need to reorder

ActiveMQ String messages get dropped?

2010-11-29 Thread Jakub Moskal
Hi, I just started using Camel because apparently this is the way to go if I need to reorder messages by their priority in the ActiveMQ. Here is my setup: Two producers (A and B) publish to OUT topic. Producer A sends messages with priority 4, producer B with priority 9. There is one subscriber t

Re: JAXB causing Unit Test Failure without any actual marshalling active

2010-11-29 Thread enalposi
Willem - I should upgrade to 2.5 first and see if I can reproduce but it's not as straight forward as hoped I am afraid. Btw - I am defining the routes programmatically at startup time such as - ... RouteBuilder { public void configure() { from(source).process(myProcessor).to(destination);

Re: ActiveMQ server with Camel and smtp component

2010-11-29 Thread Remi Malessa
Thanks , that worked. Remi On 11/29/2010 03:14 PM, Claus Ibsen wrote: You also need camel-mail JAR in the lib of AMQ. + all the other JARs listed previously. On Mon, Nov 29, 2010 at 4:07 PM, Remi Malessa wrote: Thanks for the list Claus. I've added the jars and I'm getting exactly the same

Re: ActiveMQ server with Camel and smtp component

2010-11-29 Thread Claus Ibsen
You also need camel-mail JAR in the lib of AMQ. + all the other JARs listed previously. On Mon, Nov 29, 2010 at 4:07 PM, Remi Malessa wrote: > Thanks for the list Claus. > > I've added the jars and I'm getting exactly the same message again: " > >    Failed to resolve endpoint: smtp://mysmtpserv

Re: ActiveMQ server with Camel and smtp component

2010-11-29 Thread Remi Malessa
Thanks for the list Claus. I've added the jars and I'm getting exactly the same message again: " Failed to resolve endpoint: smtp://mysmtpserver.com due to: No component found with scheme: smtp Can you tell me, if I have to add the component to my camel.xml , file, soething like:

Re: Question on VM Endpoint, multipleConsumers and OSGi

2010-11-29 Thread klausb
Ok, but should it work? Is my assumption correct? klaus. -- View this message in context: http://camel.465427.n5.nabble.com/Question-on-VM-Endpoint-multipleConsumers-and-OSGi-tp3284450p3284467.html Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Question on VM Endpoint, multipleConsumers and OSGi

2010-11-29 Thread Claus Ibsen
Hi Try from an unit test outside Karaf / OSGi first, to make sure it works there. Then we know its more an issue when using OSGi. On Mon, Nov 29, 2010 at 3:13 PM, klausb wrote: > > I'm using camel 2.5.0 and try to setup a simple pub-sub behavior among three > OSGi bundles. > One bundle (writer

Re: Best practices to measure time taken between two points of a route?

2010-11-29 Thread Claus Ibsen
Hi You can use an InterceptStrategy to do the timing. See more at: http://camel.apache.org/advanced-configuration-of-camelcontext-using-spring.html If you just want to time when sending to some endpoint then you can use an EventNotifier http://camel.apache.org/eventnotifier-to-log-details-about-

Question on VM Endpoint, multipleConsumers and OSGi

2010-11-29 Thread klausb
I'm using camel 2.5.0 and try to setup a simple pub-sub behavior among three OSGi bundles. One bundle (writer) is sending messages via to("vm:discovery?multipleConsumers=true") The two other bundles (listener) receive messages via from("vm:discovery?multipleConsumers=true") All bund

Best practices to measure time taken between two points of a route?

2010-11-29 Thread Sergey_Zhemzhitsky
Hi there, I need to take some performance metrics of camel routes. Is there any best practice to measure time taken to process some part of the route between two points of this route? I would like my camel routes to stay clean, I mean without logic to take performance metrics. Best Regards, S

Re: Problem with my first aggregate Route (newbie to Camel)

2010-11-29 Thread Claus Ibsen
On Mon, Nov 29, 2010 at 1:48 PM, Marco Bettiol wrote: > Claus... It's me again. Sorry. > I moved the filter logic to the AggregateStrategy > I tried some variants to insert "end()" such as: > > > from("file:/Users/marcobettiol/IES/data?noop=true") > > .split(body().tokenize("\n"), new TVCEOrderAgg

Re: Problem with my first aggregate Route (newbie to Camel)

2010-11-29 Thread Marco Bettiol
Claus... It's me again. Sorry. I moved the filter logic to the AggregateStrategy I tried some variants to insert "end()" such as: from("file:/Users/marcobettiol/IES/data?noop=true") .split(body().tokenize("\n"), new TVCEOrderAggregateStrategy()) .end() .to("file:/Users/marcobettiol/IES/copy?au

Re: ActiveMQ server with Camel and smtp component

2010-11-29 Thread Claus Ibsen
Hi You need the JARs which is listed as compile. [INFO] The following files have been resolved: [INFO]aopalliance:aopalliance:jar:1.0:compile [INFO]commons-logging:commons-logging:jar:1.1.1:test [INFO]commons-logging:commons-logging-api:jar:1.1:compile [INFO]javax.activation:acti

Re: How to unmarshal a soap response

2010-11-29 Thread davsclaus
What errors do you see when you do unmarshal? And a good idea is to look at some unit tests from camel-soap component. Camel will automatic throw an exception if HTTP status != 200. So you can use Camel error handling to cater for that. http://camel.apache.org/error-handling-in-camel.html You

ActiveMQ server with Camel and smtp component

2010-11-29 Thread Remi Malessa
Hi. I have ActiveMQ 5.4.1 . It seems like it doesn't have the smtp component libraries by default. I've tried to juggle with the Camel (on its own) installation but I've got it all mixed up. Could somebody tell me please , how to deal with it properly ? There is a note for Maven users at :http

Re: Problem with my first aggregate Route (newbie to Camel)

2010-11-29 Thread Claus Ibsen
On Mon, Nov 29, 2010 at 10:26 AM, Marco Bettiol wrote: > I'm using 2.5.0. > Ok I will try with your solution and let you know. :) > P.S. > Just for knowledge... Is my code right? > No the filter should not be in the split. Camel will always invoke the AggregationStrategy for each splitted message

Re: Integration camel and spring-integration

2010-11-29 Thread Bingliu
Thanks, the problem has been solved.I configure the "inOut=true" in the options. -- View this message in context: http://camel.465427.n5.nabble.com/Integration-camel-and-spring-integration-tp3284105p3284149.html Sent from the Camel - Users mailing list archive at Nabble.com.

Re: onCompletion for failed exchanges

2010-11-29 Thread Bengt Rodehav
Claus, I did add two but that won't work since they are mutually exclusive - adding the second one will negate the first one. I assume then, that the Exchange.EXCHANGE_CAUGHT property is the way to go. /Bengt 2010/11/29 Claus Ibsen : > On Mon, Nov 29, 2010 at 10:05 AM, Bengt Rodehav wrote: >> C

Re: Integration camel and spring-integration

2010-11-29 Thread Claus Ibsen
Hi Looks like you either have to set MEP to InOnly or add an inputChannel option on the spring-integration endpoint so it knows where to receive the reply from SI. Of course the Camel component should have better validation so it can thrown a better error message. I will create a ticket. On Mon

Performance issues when using camel-activemq and transactions.

2010-11-29 Thread Ioannis Canellos
I am using camel 2.5.0 and activemq 5.4.0 to create a simple route of the form dataset -> activemq:queue.in -> activemq:queue.out -> dataset. All are working fine and I the performance is more than 1K messages/sec. However if I set transactions=true on the activemq component configuration, then I

Re: Problem with my first aggregate Route (newbie to Camel)

2010-11-29 Thread Marco Bettiol
I'm using 2.5.0. Ok I will try with your solution and let you know. :) P.S. Just for knowledge... Is my code right? 2010/11/29 Claus Ibsen > Hi > > What version of Camel are you using? > > And you can also do your filter logic in the aggregator. Just return > oldExchange if the newExchange shoul

Integration camel and spring-integration

2010-11-29 Thread Bingliu
Hi, I am integrating camel and spring-integration now. Please look this: the spring-integration configuration is this : but a problem has occur

Re: Problem with my first aggregate Route (newbie to Camel)

2010-11-29 Thread Claus Ibsen
Hi What version of Camel are you using? And you can also do your filter logic in the aggregator. Just return oldExchange if the newExchange should be skipped. On Sun, Nov 28, 2010 at 9:39 PM, Marco Bettiol wrote: > Hi guys, > > I'm new to apache Camel. It sound really great. > > I was trying t

Re: onCompletion for failed exchanges

2010-11-29 Thread Claus Ibsen
On Mon, Nov 29, 2010 at 10:05 AM, Bengt Rodehav wrote: > Claus, > > I tried to use both "onCompleteOnly" and "onFailureOnly" but ran into > problems. Looking at the source code, it seems like they are mutually > exclusive and only the last one will take effect. > > In my case I always want to be n

Re: onCompletion for failed exchanges

2010-11-29 Thread Bengt Rodehav
Claus, I tried to use both "onCompleteOnly" and "onFailureOnly" but ran into problems. Looking at the source code, it seems like they are mutually exclusive and only the last one will take effect. In my case I always want to be notified when an exchange is completed, both when it succeeds and whe