Re: onException()

2010-03-24 Thread Claus Ibsen
On Wed, Mar 24, 2010 at 11:30 PM, /U wrote: > > thnaks for the help - it works. Only problem: > if connection to toUri fails, MyErrorhandler is > invoked; but if connection to fromUri fails, > MyErrorHandler not invoked! > > for example, > > from("file://a.log").onException(Exception.class).proces

Re: How to invoke specific operation with params for cxf webservice endpoint through configuration

2010-03-24 Thread Ashwin Karpe
Hi, You do need to create a client to invoke on the CXF endpoint and send a SOAP payload that can be used to call your method described in WSDL. If you do not want to write a client you could use a tool like SoapUI to do this for you (since you already have the WSDL). Cheers, Ashwin... usha

Re: onException()

2010-03-24 Thread Ashwin Karpe
Hi, The exception handler (MyErrorHandler) only comes into play once the file is read and routed to the to(destinationURI). The exception handler cannot come into play if there is a problem setting up a Consumer connection in the from(sourceURI). This is natural since if there is a problem with

How to invoke specific operation with params for cxf webservice endpoint through configuration

2010-03-24 Thread usha K.
I have the following cxfEndpoint configuration in the camel-context.xml which is a webservice end point, pointing to a 3rd party web service. I am wondering how I can specify (in this configuration) an operation with parameters to be passed to the webservice? As an example, I need to invoke the

Possible cause of slow

2010-03-24 Thread Muhammad Ichsan
Dear All I have strange problem in Camel. I use routingSlip like the following: ... ... There was no problem before in flowing in a 4-endpoint routing slip. But now, the third of the endpoints is visited 30s-38s since last endpoint is visited. What are the possible causes? This are the d

Re: onException()

2010-03-24 Thread /U
thnaks for the help - it works. Only problem: if connection to toUri fails, MyErrorhandler is invoked; but if connection to fromUri fails, MyErrorHandler not invoked! for example, from("file://a.log").onException(Exception.class).process(MyErrHandler).to("ftp://u...@server?";).end() is wo

Building camel from source deletes C:\Temp\*

2010-03-24 Thread Jim Talbut
Hi, Building camel from source on Windows (Vista 64 bit) deletes everything in C:\Temp\* I think it's one of the unit tests but a quick look hasn't shown up which. That is a major bad thing for it to do - it's deleted lots of things from my machine that I did not want to lose. Jim

Re: FileConsumer always reads the data in system charset/encoding

2010-03-24 Thread Kevin Jackson
Hi, To clear this whole thing up - I can now report that everything is working as expected, the problem was (and still is) with Spring's transactional test support, not rolling back the data that my processing is adding to the database. This meant that I was checking against an old value in the d

Re: FileConsumer always reads the data in system charset/encoding

2010-03-24 Thread Kevin Jackson
Hi, > No it does not read the file beforehand. > > Use Tracer to see the Message Body. > And you have not stated which version of Camel you are using, despite > its highlighted on the how to get support page > http://camel.apache.org/support.html > > Also you should check JIRA etc if there was a k

Re: error-handling advice with queues

2010-03-24 Thread Allen Lau
Look at these pages for samples. http://camel.apache.org/splitter.html http://camel.apache.org/content-based-router.html I would most likely create a POJO to split the message up and then use the content base router to route the message. On Wed, Mar 24, 2010 at 9:04 AM, jfaath wrote: > > I'll

Re: FileConsumer always reads the data in system charset/encoding

2010-03-24 Thread Claus Ibsen
No it does not read the file beforehand. Use Tracer to see the Message Body. And you have not stated which version of Camel you are using, despite its highlighted on the how to get support page http://camel.apache.org/support.html Also you should check JIRA etc if there was a known issue with it

Re: FileConsumer always reads the data in system charset/encoding

2010-03-24 Thread Kevin Jackson
Hi, Here is my route: http://camel.apache.org/schema/spring";> The file is encoded as i

Re: error-handling advice with queues

2010-03-24 Thread jfaath
I'll give this a shot. Can you give me a quick example or point me to a sample that does something similar (ex. setting a header in code, performing conditional logic in a route based on a header). -JF Allen Lau-2 wrote: > > I could be wrong here, but you could easily stick the "error" object

Re: FileConsumer always reads the data in system charset/encoding

2010-03-24 Thread Kevin Jackson
Hi, > Use > .convertBodyTo(String.class, "utf-8") after the from(file:xxx) to > control the charset used for encoding. Fantastic - should have asked earlier before digging through the src - C'est la vie Kev

Re: FileConsumer always reads the data in system charset/encoding

2010-03-24 Thread Claus Ibsen
Hi Use .convertBodyTo(String.class, "utf-8") after the from(file:xxx) to control the charset used for encoding. On Wed, Mar 24, 2010 at 4:25 PM, Kevin Jackson wrote: > Hi, > > I have a camel application deployed on RHEL5 with a default > encoding/locale of UTF-8 > > I have to download data fro

FileConsumer always reads the data in system charset/encoding

2010-03-24 Thread Kevin Jackson
Hi, I have a camel application deployed on RHEL5 with a default encoding/locale of UTF-8 I have to download data from a remote Windows server (CP1251 or ISO-8859-1/latin-1) My route breaks down the processing of the files into two steps: 1 - download 2 - consume and pass split/tokenized String/b

Re: JMS send Timeout

2010-03-24 Thread Claus Ibsen
On Wed, Mar 24, 2010 at 3:31 PM, Leen Toelen wrote: > Hi, > > what I would like as a result is that the HTTP generates a 200 OK as > soon as possible, and if the ActiveMQ queue is being throttled I > generate a 503 Service Temporarily Unavailable. > You have to ask at AMQ forum as its about its c

Re: JMS send Timeout

2010-03-24 Thread Leen Toelen
Hi, what I would like as a result is that the HTTP generates a 200 OK as soon as possible, and if the ActiveMQ queue is being throttled I generate a 503 Service Temporarily Unavailable. Regards, Leen On Wed, Mar 24, 2010 at 12:23 PM, Charles Moulliard wrote: > Maybe, you should consider to use

Re: Unable to throw Soap Fault

2010-03-24 Thread William Tam
BTW, CAMEL-2544 and CAMEL-2495 are issues for throwing Application SOAP Fault when the CXF endpoint is in PAYLOAD mode and no SEI (serviceClass) is provided. William Tam wrote: I think it is hard to workaround the problem. If you can rebuild just the camel-cxf component yourself, you can mer

Re: Unable to throw Soap Fault

2010-03-24 Thread William Tam
I think it is hard to workaround the problem. If you can rebuild just the camel-cxf component yourself, you can merge the fix (the change is quite small). Please make sure you pick up https://issues.apache.org/activemq/browse/CAMEL-2544 too. Willem Jiang wrote: I'm afraid CXF interceptor c

Re: Not able to invoke webservice using http component

2010-03-24 Thread Willem Jiang
Hi, You can try to use the soap dataformat[1] which is new to Camel 2.3.0. And you need to download the Camel 2.3.0-SNAPSHOT for it. [1]http://camel.apache.org/soap.html Willem Harbeer Kadian wrote: Hi, thanks for the reply. I did not changed the input soap message into Document and di

Re: Unable to throw Soap Fault

2010-03-24 Thread Willem Jiang
I'm afraid CXF interceptor can help you to do that,as we setup some customer interceptor when the camel-cxf endpoint working in PAYLOAD dataformat. Can you try the latest Camel to see if the Error still there? BTW, is there any stack trace in the log that can help us trace the issue ? Willem

Re: Problems with paths.

2010-03-24 Thread Claus Ibsen
The move options is relative to where the file was picked up. But the game changes when you use ${ } Read more at - Fine grained control over Move and PreMove option http://camel.apache.org/file2.html On Wed, Mar 24, 2010 at 11:52 AM, ankelee wrote: > > Hi - this might not be strictly Camel que

Re: Not able to invoke webservice using http component

2010-03-24 Thread Harbeer Kadian
Hi, thanks for the reply. I did not changed the input soap message into Document and directly sent it. I got the soap message reply in the form of String. The reply is as follows http://schemas.xmlsoap.org/soap/envelope/"; xmlns:xsd="http://www.w3.org/2001/XMLSchema"; xmlns:xsi="http://www.w3.org

Re: JMS send Timeout

2010-03-24 Thread Charles Moulliard
Maybe, you should consider to use an async route : http://camel.apache.org/asynchronous-processing.html Kind regards, Charles Moulliard Senior Enterprise Architect Apache Camel Committer * blog : http://cmoulliard.blogspot.com twitter : http://twitter.com/cmoulliard L

JMS send Timeout

2010-03-24 Thread Leen Toelen
Hi, I have an HTTP endpoint that submits messages to an ActiveMQ queue. When the consumer gets slow, the Queue is throttled and the HTTP call hangs infinitely. Is there a way to tell the broker that if a JMS message is not accepted within a timeout, the exchange is interrupted and the HTTP endpoin

Problems with paths.

2010-03-24 Thread ankelee
Hi - this might not be strictly Camel question but here goes: I'm having some problems finding handling different paths when working with files in Camel: from("file://data/in/inbox?move=data/in/backup/${date:now:MMddhh}/${file:name}")...etc I have a standard Eclipse project with /bin and /s

Re: Unable to throw Soap Fault

2010-03-24 Thread HiS
Hi, For generalization I had written the endpoint as ("http:requestset"), but this is actually a custom endpoint which internally uses CXF to create the web-service endpoint. Its working fine when sending normal response but only when soap fault needs to be returned does is not work. We can't

Re: Unable to throw Soap Fault

2010-03-24 Thread HiS
Hi, I tried setting the Soap Fault in exchange.setException() but that also is not working. Still getting the soap envelope with empty body. Just wondering if you are using camel 2.0.0 too, coz then I can be sure this issue is not due to the specific version. Thanks, Himanshu Jim Talbut wro

Re: Unable to throw Soap Fault

2010-03-24 Thread Willem Jiang
Hi, Is the from("http:requestset") a CXF endpoint or other something ? I just went through the CxfConsumer code of camel trunk, it should be able to deal with the fault message that you set in the ErrorProcessor. If you can't upgrade the Camel version, I'm afraid you need to buy a customer su

Re: quartz + pollEnrich +sftp ==> 'move' parameter ignored

2010-03-24 Thread Claus Ibsen
Hi If you want to store to a file directory directly from FTP you can use localWorkDirectory option, while causes Camel to stream directly to a temp file in the directory. But then if you do .to("file:xxx") afterwards then Camel can do a fast IO move operation. Then I assume the SFTP consumer woul

Re: Unable to throw Soap Fault

2010-03-24 Thread Jim Talbut
Hi, I'm no expert on this, but have you tried setting it as an exception instead? This is working for me: public class SoapFaultConversionProcessor implements Processor { private static final String ANONYMOUS_FAULT_STRING = "An unexpected error has occured."; private static final Logger

Re: Unable to throw Soap Fault

2010-03-24 Thread HiS
Hi Willem, Thanks for your response. I am having the following groovy route: from("http:requestset") .onException(Exception.class) .handled(true) .processRef('ErrorProcessor').end() .process(new ValidateRequestProcessor()); Here the 'ValidateRequestProcessor' validates the reques