Re: exception in load-testing using DataSet component

2009-12-14 Thread Willem Jiang
Hi, It looks like the exception is thrown when the camel context is stopping and your dataset is still sending the data. When you call assertMockEndpointsSatisfied(), camel will try to wait for the message for about 30 second. If send a large amount of message, you need to add some sleep ti

Re: exception in load-testing using DataSet component

2009-12-14 Thread Claus Ibsen
On Mon, Dec 14, 2009 at 9:09 AM, Willem Jiang wrote: > Hi, > > It looks like the exception is thrown when the camel context is stopping and > your dataset is still sending the data. > > When you call assertMockEndpointsSatisfied(), camel will try to wait for the > message for about 30 second. > >

Re: camel-jetty and loadbalancing

2009-12-14 Thread Willem Jiang
Can you add this option into your http producer's URI? bridgeEndpoint=true With this option set to be true, HttpProducer will ignore the Exchange.HTTP_URI header, and use the endpoint's URI for request. So you will not get host parameter is null error. Willem Charles Moulliard wrote: I have

Re: camel-jetty and loadbalancing

2009-12-14 Thread Charles Moulliard
Using this option, I get the following error : org.apache.camel.component.http.HttpOperationFailedException: HTTP operation failed invoking http://0.0.0.0:8282/reportservice/incidents with statusCode: 407 at org.apache.camel.component.http.HttpProducer.populateHttpOperationFailedException(Http

Re: camel-jetty and loadbalancing

2009-12-14 Thread Willem Jiang
Hi Charles, Please check out this option for http producer. throwExceptionOnFailure true Camel 2.0: Option to disable throwing the HttpOperationFailedException in case of failed responses from the remote server. This allows you to get all responses regardles of the HTTP status code. [1]

Re: camel-jetty and loadbalancing

2009-12-14 Thread Charles Moulliard
If I use this option, I get now : org.apache.commons.httpclient.NoHttpResponseException: The server localhost failed to respond at org.apache.commons.httpclient.HttpMethodBase.readStatusLine(HttpMethodBase.java:1976) at org.apache.commons.httpclient.HttpMethodBase.readResponse(HttpMethodBa

Re: Not possible to use onException and doTry()... doFinally() ?

2009-12-14 Thread Claus Ibsen
On Fri, Dec 11, 2009 at 11:21 PM, Dragisa Krsmanovic wrote: > In this route, although message, correctly, does not get to mock:end, it > does not seem to go to mock:error either. > doTry .. doCatch .. doFinally does NOT use regular error handling. Its in fact its own little error handler where yo

Re: recipientList onException redelivery

2009-12-14 Thread Claus Ibsen
On Thu, Dec 10, 2009 at 1:42 PM, Claus Ibsen wrote: > On Thu, Dec 10, 2009 at 1:19 PM, mcrive wrote: >> >> Hi, >> i am using recipientList with the cool parallelProcessing feature added on >> camel 2.2. >> it works like a charm. >> >> the recipientList contains a csv list of ftp endpoints. I woul

Re: camel-jetty and loadbalancing

2009-12-14 Thread Charles Moulliard
Here is the trace received using tcpmon request send : GET /reportservice/incidents/123/ HTTP/1.1 Host: localhost: User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accep

Re: camel-jetty and loadbalancing

2009-12-14 Thread Charles Moulliard
I think that my problem is related to camel-1925 Here is the message received when using options uri : uri=" http://localhost:8282?throwExceptionOnFailure=false&bridgeEndpoint=true"; GET /reportservice/incidents/123/ HTTP/1.1 Host: localhost: User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.

Filename based on XPath result

2009-12-14 Thread Martin Gilday
Hi, I have a StringMessage which contains and XML body. I would like to use a unique part of the body as the filename in conjunction with the file component. Is it possible to consume from JMS and send to file with the filename the result of an XPath match? Thanks, Martin.

Re: Filename based on XPath result

2009-12-14 Thread Claus Ibsen
On Mon, Dec 14, 2009 at 11:55 AM, Martin Gilday wrote: > Hi, > > I have a StringMessage which contains and XML body.  I would like to use > a unique part of the body as the filename in conjunction with the file > component.  Is it possible to consume from JMS and send to file with the > filename t

Re: Filename based on XPath result

2009-12-14 Thread Martin Gilday
Hi, Yes that is how we thought it should be. However we have come across the following issue. The first route works as desired. The second and third do not compile. // Works from("direct:test").setHeader("foo") .xpath("/bar") .to("cheese"); //The method to(String) is undefined for the typ

Re: exception in load-testing using DataSet component

2009-12-14 Thread Nick Chistyakov
Hello Willem and Clause! Thank you for response. I added: mockEndpoint.await(1, TimeUnit.MINUTES); and the test now runs fine :)) Best of the best regards, Nick On Mon, Dec 14, 2009 at 11:11 AM, Claus Ibsen wrote: > On Mon, Dec 14, 2009 at 9:09 AM, Willem Jiang > wrote: > > Hi, > > > > It l

Re: Filename based on XPath result

2009-12-14 Thread Claus Ibsen
On Mon, Dec 14, 2009 at 2:03 PM, Martin Gilday wrote: > Hi, > > Yes that is how we thought it should be.  However we have come across > the following issue.  The first route works as desired.  The second and > third do not compile. > > // Works > from("direct:test").setHeader("foo") >  .xpath("/ba

RSS with proxy details

2009-12-14 Thread jpcook
Hello, I am trying to use the RSS component with a proxy server but it doesn't appear to support this via parameters or in an obvious way? I created a similar patch for the http component a while ago but am surprised something like this isn't supported via the RSS component? Thanks Jonathan --

onException() silently ignored if after transacted()

2009-12-14 Thread Dragisa Krsmanovic
Here is me with more questions/bug report. I've noticed that Camel can be very sensitive on order operators are invoked in route builder. For example, transacted() has to be after onException(). Otherwise, onException() is completely ignored and message will just pass through error handling code

Re: onException() silently ignored if after transacted()

2009-12-14 Thread Claus Ibsen
Hi Yeah we will in the future break up the DSL to have a route setup part and then the regular part for the route flow. The former should setup onException, transaction, onCompletion, interceptors and what not, eg cross function stuff. And the latter is for the route. The problem is that its curr

Re: RSS with proxy details

2009-12-14 Thread Claus Ibsen
On Mon, Dec 14, 2009 at 5:17 PM, jpcook wrote: > > Hello, > > I am trying to use the RSS component with a proxy server but it doesn't > appear to support this via parameters or in an obvious way? I created a > similar patch for the http component a while ago but am surprised something > like this

Re: ActiveMQ 5.3.0 and PollingConsumer

2009-12-14 Thread Dragisa Krsmanovic
Here is more details. On Fri, 2009-12-11 at 10:42 -0800, Dragisa Krsmanovic wrote: > @Test > @DirtiesContext > public void test() throws InterruptedException { > endpoint.setResultWaitTime(1l); > endpoint.expectedMessageCount(1); > endpoint.message(0).body().isEqualTo("foo/ba

maven pom unable to resolve artifact?

2009-12-14 Thread Gareth Williams
I have a camel 2.0 project, and I am using maven. if i type mvn clean compile camel:run I get Missing indirectly referenced artifact org.springframework.javaconfig:org.springframework.config.java:jar:1.0.0-20090215:compile ... Path to dependency: 1) com.evolok:eventbroker:jar:1.1.0-SNA

Re: maven pom unable to resolve artifact?

2009-12-14 Thread Jon Anstey
Try adding this repo: camel.internal.maven.repository Camel internal Maven Repo http://svn.apache.org/repos/asf/camel/m2-repo On Mon, Dec 14, 2009 at 3:23 PM, Gareth Williams < gareth.willi...@firstclarity.com> wrote: > > I have a camel 2.0 project, and I am using maven. if i type > mvn

Help to understand xpath expression in camel routebuilder

2009-12-14 Thread Kenneth H
Hi, I'm trying to udnerstand a camel example, but I'm stuck at a poit where xpath is used. The builder is shown here: public void configure() { from(SERVICE_IN) // SERVICE_IN = jbi:service:http://esbinaction.com/insurance/insuranceDSLRouter .convertBodyTo(

Re: HTTPS authentication setup using camel-http

2009-12-14 Thread ychawla
Is it possible to do this same 'hookup' using the Spring DSL. I am not sure if it is possible to specify this in Spring: HttpComponent httpComponent = (HttpComponent) getContext().getComponent("http"); httpComponent.setHttpClientConfigurer(new MyHttpClientConfigurer()); bwhite wrote: > > Tha

Re: Help to understand xpath expression in camel routebuilder

2009-12-14 Thread Jon Anstey
The xpath expression is going to be evaluated against the incoming message body. So, if we have a message like: http://dzone.com/insurance";> ... the first when clause will evaluate to true since the xpath expression is searching for any element like "TravelInsuranceRequest". The namespace bit

Re: HTTPS authentication setup using camel-http

2009-12-14 Thread Claus Ibsen
On Mon, Dec 14, 2009 at 8:30 PM, ychawla wrote: > > Is it possible to do this same 'hookup' using the Spring DSL.  I am not sure > if it is possible to specify this in Spring: > > HttpComponent httpComponent = (HttpComponent) > getContext().getComponent("http"); > httpComponent.setHttpClientConfig

Re: recipientList onException redelivery

2009-12-14 Thread mcrive
Claus Ibsen-2 wrote: > > I have worked on this and committed a fix. Can you test it on your end? > Hi Claus, sorry for the late reply but I just came to the office (I am traveling a lot) I am currently compiling latest revision and will test it soon. Thanks, Marco -- View this message in co

Re: recipientList onException redelivery

2009-12-14 Thread mcrive
I've just a little but of testing and it looks like it works fine.:clap: I'll develop an application on top of recipientList so I'll let you know if I find new issues with regard to this matter. thanks for the fix!! camel is my best friend :drunk: mcrive wrote: > > > Claus Ibsen-2 wrote: >>

recipientList + aggregationStrategy, maximumRedeliveries exceeded

2009-12-14 Thread mcrive
I am using Camel 2.2 (rev 890454) How is it possible to know if an exchange has exceeded the maximumRedeliveries configured on the route by using aggregationStrategy and if it hasn't how many redelivery have been attempted? route sample: from("direct:delivery.notification.test") .onException(Ex

Re: HTTPS authentication setup using camel-http

2009-12-14 Thread ychawla
Hi Gang, I added an update to the WIKI with some more info on doing this with Spring: http://cwiki.apache.org/confluence/display/CAMEL/HTTP I hope this is okay. Here are the details: If you are doing this using the Spring DSL, you can specify your HttpClientConfigurer using the URI. For example

start/stop routes programmatically

2009-12-14 Thread boday
I see that Camel 2.1 now support starting/stopping routes via JMX/APIs. But, how do I identify routes properly at runtime... For example, assume I have the following route... from("activemq:queue1").to("activemq:queue2"); from("activemq:queue2").to("activemq:queue3"); They show up in JMX as "r

Re: start/stop routes programmatically

2009-12-14 Thread Willem Jiang
Yes, supporting to set the route name would be very useful when you want manage the route states from JMS or API. I just created a JIRA[1] for it. [1] https://issues.apache.org/activemq/browse/CAMEL-2290 Willem boday wrote: I see that Camel 2.1 now support starting/stopping routes via JMX/AP

Re: start/stop routes programmatically

2009-12-14 Thread Jon Anstey
You can set custom ids for each route like this: from("activemq:queue1").id("InboundRoute").to("activemq:queue2"); from("activemq:queue2").id("ProcessingRoute").to("activemq:queue3"); in the Spring DSL you can just use standard id attributes like: ... ... On Mon, Dec 14, 2009 at 9:45 PM, boday

Re: start/stop routes programmatically

2009-12-14 Thread Willem Jiang
Hi Jon, After checking the code, I think the DSL should be from("activemq:queue1").routeId("InboundRoute").to("activemq:queue2"); from("activemq:queue2").routeId("ProcessingRoute").to("activemq:queue3"); Willem Jon Anstey wrote: You can set custom ids for each route like this: from("activemq:

Re: start/stop routes programmatically

2009-12-14 Thread Jon Anstey
Ha! This must have changed since the last time I used it ;) On Mon, Dec 14, 2009 at 11:15 PM, Willem Jiang wrote: > Hi Jon, > > After checking the code, I think the DSL should be > from("activemq:queue1").routeId("InboundRoute").to("activemq:queue2"); > from("activemq:queue2").routeId("Processing

Re: start/stop routes programmatically

2009-12-14 Thread Willem Jiang
If you are using camel 2.0, you may need to use id() dsl, but for camel 2.1 you can use the routeId() dsl. You can find more information here[1] [1] https://issues.apache.org/activemq/browse/CAMEL-2109 Willem Willem Jiang wrote: Hi Jon, After checking the code, I think the DSL should be from

Re: recipientList + aggregationStrategy, maximumRedeliveries exceeded

2009-12-14 Thread Claus Ibsen
On Mon, Dec 14, 2009 at 11:30 PM, mcrive wrote: > > I am using Camel 2.2 (rev 890454) > > How is it possible to know if an exchange has exceeded the > maximumRedeliveries configured on the route by using aggregationStrategy and > if it hasn't how many redelivery have been attempted? > > route samp