Re: Modifying route using adviceWith showing inconsistent behaviour

2011-02-08 Thread Sumit Teke
Still not able to find a way. Can anyone help please. Thanks, Sumit Teke On Tuesday 08 February 2011 10:20 AM, Sumit Teke wrote: Hi Ashwin, Sorry i think, i was not clear in last post. I understand that stopping camel context will stop all the routes. What i did was *Test 1: *Tried stop

Re: Redelivery policy and delay pattern

2011-02-08 Thread Claus Ibsen
On Tue, Feb 8, 2011 at 8:56 PM, swwyatt wrote: > > I am using this policy: > > delayPattern="0:1000;1:1;2:3"/> > > My observation is that the first delay is 10 seconds, not 1 second. The next > 2 deliveries have a 30 second delay. Is delay pattern 0 based? The > documentation shows it thi

Re: How to extend the Spring DSL ?

2011-02-08 Thread Willem Jiang
On 2/8/11 11:15 PM, sebastien.petrucci wrote: Hi gurus, I am currently developing some specific extensions for Camel. Today, it looks like that: (declaring spring bean using custom XML) To make it easier for my customers, I would like to extend the Spring DSL and end up wi

Re: SFTP - trigger consuming of a file wont delete or move file

2011-02-08 Thread davsclaus
See CAMEL-3427: ConsumerTemplate expose doneUoW you may need in special cases. Added javadoc why and when. -- View this message in context: http://camel.465427.n5.nabble.com/SFTP-trigger-consuming-of-a-file-wont-delete-or-move-file-tp3376663p3377094.html Sent from the Camel - Users mailing list

Re: SFTP - trigger consuming of a file wont delete or move file

2011-02-08 Thread davsclaus
Please always write what version of the software you are using! And try upgrading and use the latest released version to see if its working/fixed there. -- View this message in context: http://camel.465427.n5.nabble.com/SFTP-trigger-consuming-of-a-file-wont-delete-or-move-file-tp3376663p3377092

Re: Testing the subscription

2011-02-08 Thread davsclaus
Then don't use nabble to post, but your existing mail client. eg if you use google mail then its just your web browser. If you use MS outlook then use that. Check in your spam folder if mails from the Camel user list is moved there by your mail client/server. -- View this message in context: ht

Re: Need to use Spring DSL instead of Java DSL for a specific use case

2011-02-08 Thread davsclaus
And you would need to lookup what's the value of this key: JcrConstants.JCR_NODE_NAME Eg check the source code / JAR what the value is, and type that instead. The source is here: http://camel.apache.org/source.html in the camel-jcr component https://svn.apache.org/repos/asf/camel/trunk/component

Re: Need to use Spring DSL instead of Java DSL for a specific use case

2011-02-08 Thread davsclaus
Don't use the setBody inside setProperty as its not allowed. You should do like this: ${body} If you use Camel 2.3 or better you can convert the body to the type you wanted http://camel.apache.org/simple ${bodyAs(String)} Instead of simple you can use any of the scripting

Re: Need to use Spring DSL instead of Java DSL for a specific use case

2011-02-08 Thread Ashwin Karpe
Hi, Please find your answer below :) Cheers, Ashwin... === http://www.springframework.org/schema/beans"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation=" http://www.springframework.org/schema/beans

SFTP - trigger consuming of a file wont delete or move file

2011-02-08 Thread watcher
Hi I trying to trigger a archive of a file on a sftp server on demand. Bascially a message is sent to a queue with a filename, that file is then consumed and should be sent to an archive folder on the sftp server. It appears that it will not work in case 2 but does work in case one. I've setup

Re: Event driven FTP consumer?

2011-02-08 Thread Richard Kettelerij
Alright forget about the pollEnrich(). Basically what i need is producer that can read files from an FTP server so I can wrap it in a to() (or an enrich() for that matter). -- View this message in context: http://camel.465427.n5.nabble.com/Event-driven-FTP-consumer-tp3376242p3376598.html Sent fr

Re: Event driven FTP consumer?

2011-02-08 Thread Richard Kettelerij
Oh no that's not what I meant. Sorry for the confusion. What I would like to do is just read something from a FTP server on-demand, so without polling or at least without polling for more than a few seconds. Therefore I either need a producer that can read files from an FTP server and wrap it in

Redelivery policy and delay pattern

2011-02-08 Thread swwyatt
I am using this policy: My observation is that the first delay is 10 seconds, not 1 second. The next 2 deliveries have a 30 second delay. Is delay pattern 0 based? The documentation shows it this way. -- View this message in context: http://camel.465427.n5.nabble.com/Redelivery-policy-and-del

Re: Problems with multiple threads on FlatPack component

2011-02-08 Thread Xavier Coulon
Damn', I should have seen it. Thank you, Richard. Regards, Xavier On Tue, Feb 8, 2011 at 7:56 PM, Richard Kettelerij < richardkettele...@gmail.com> wrote: > > As you can see from the stacktrace a SimpleDateFormat is used under the > hood. > SimpleDateFormat isn't thread safe. > -- > View this me

Re: Event driven FTP consumer?

2011-02-08 Thread Hadrian Zbarcea
Richard, the way you phrased it, having an event driven consumer, effectively means having camel act as an FTP server (or a proxy for an ftp server). That could be done with camel-mina, I am pretty sure, but I don't see the need. More work and no gain really. Cheers, Hadrian On Feb 8, 2011, at

Re: IllegalArgumentException: class Tracer$$EnhancerByCGLIB$$3c5de9de is not an enhanced class

2011-02-08 Thread Gert Vanthienen
L.S., The proxy gets created when you do the in your other bundles. In an OSGi world, the bundle providing the service can get updated and the proxy allows the bundle that consumes the service to handle that scenario. For your scenario, you want to be able to replace the Tracer bundle with a ne

Re: IllegalArgumentException: class Tracer$$EnhancerByCGLIB$$3c5de9de is not an enhanced class

2011-02-08 Thread Richard Kettelerij
Just a thought, have you tried switching to JDK proxies instead of CGLIB? -- View this message in context: http://camel.465427.n5.nabble.com/IllegalArgumentException-class-Tracer-EnhancerByCGLIB-3c5de9de-is-not-an-enhanced-class-tp3376259p3376433.html Sent from the Camel - Users mailing list arc

Re: Problems with multiple threads on FlatPack component

2011-02-08 Thread Richard Kettelerij
As you can see from the stacktrace a SimpleDateFormat is used under the hood. SimpleDateFormat isn't thread safe. -- View this message in context: http://camel.465427.n5.nabble.com/Problems-with-multiple-threads-on-FlatPack-component-tp3376267p3376393.html Sent from the Camel - Users mailing lis

Re: Event driven FTP consumer?

2011-02-08 Thread Richard Kettelerij
Hi Hadrian, Yeah that's exactly what I need. But I already knew that using to() wasn't going to work so I tried pollEnrich (which semantics seem to match my use case rather well) without success. Any other ideas/workarounds how to implement this, apart from CAMEL-3397 which is scheduled for Cam

Re: JMSConfiguration - Camel vs CXF

2011-02-08 Thread Christian Schneider
Ah ok .. so you still have your cxf jms config. That is fine. Using the camel transport for cxf is not that complicated but it has it´s drawbacks. For example it does not support streaming like cxf does. So as long as you don´t need to use camel and cxf in the same route you will probably be b

Re: JMSConfiguration - Camel vs CXF

2011-02-08 Thread Jeffrey Knight
On Tue, Feb 8, 2011 at 1:11 PM, Christian Schneider wrote: > Ok so you did not really need a CXF Endpoint for your current project but > only wanted to have a camel JMS config > based on a CXF JMS config? I thought you wanted CXF and Camel to work both > on the same jms config. I understood you w

Re: JMSConfiguration - Camel vs CXF

2011-02-08 Thread Christian Schneider
Ok so you did not really need a CXF Endpoint for your current project but only wanted to have a camel JMS config based on a CXF JMS config? I thought you wanted CXF and Camel to work both on the same jms config. Christian Am 08.02.2011 19:04, schrieb Jeffrey Knight: Did you also route the cx

Re: JMSConfiguration - Camel vs CXF

2011-02-08 Thread Jeffrey Knight
> Did you also route the cxf service over a camel route using the camel > transport for cxf? This is not visible in the excerpt you send. I did not (explicitly) use camel transport for CXF. I simply have the in my applicationContext.xml, which I bundled into a WAR file which I then deployed to W

Re: Camel 2.4 + Spring + JTA Tx Manager on Fuse ESB

2011-02-08 Thread Christian Müller
Hello Charles! I have posted a similar question yesterday [1]. I'm not sure if the SMX exported transaction manager is XA capable or not. I will work on a little example to figure this out, because I didn't receive a response until now. I will also try a configuration with the atomicos XA transact

Re: JMSConfiguration - Camel vs CXF

2011-02-08 Thread Christian Schneider
Great to hear that it worked so well. If you want to take the time and build an example this will surely be added to the distro. Did you also route the cxf service over a camel route using the camel transport for cxf? This is not visible in the excerpt you send. Christian Am 08.02.2011 17:4

Re: Event driven FTP consumer?

2011-02-08 Thread Hadrian Zbarcea
Not sure if I didn't misread your request. I believe that what you need is actually a file/ftp producer and then you would do: > from("servlet://my/web/service").to("ftp://f...@bar.com/baz";) See: https://issues.apache.org/jira/browse/CAMEL-3397 Hadrian On Feb 8, 2011, at 12:27 PM, Richard K

Problems with multiple threads on FlatPack component

2011-02-08 Thread Xavier Coulon
Hello, I'm trying to consume messages from a seda component with multiple threads. Those String-based messages are lines coming from a flat file that I want to parse with the FlatPack component/marshaller. [Later on, those Java Map-based messages will be converted into Entities and persisted with

IllegalArgumentException: class Tracer$$EnhancerByCGLIB$$3c5de9de is not an enhanced class

2011-02-08 Thread Christian Müller
Hello List! My environment is ServiceMix 4.2.0-fuse-02-00 and Camel 2.2.0-fuse-02-00. I'm not sure whether this problem is related to ServiceMix or Camel. In our integration solution, we developed our own Tracer, whcih extends org.apache.camel.processor.interceptor.Tracer. We have to do this, bec

Event driven FTP consumer?

2011-02-08 Thread Richard Kettelerij
Hi, I have a use case were I need to read some files from a FTP server in case a HTTP request is received. More precisely: I have a webservice and when this webservice is invoked through a HTTP request I'd like to read files from a FTP server and return the content as a HTTP response through the

Re: JMSConfiguration - Camel vs CXF

2011-02-08 Thread Jeffrey Knight
On Tue, Feb 8, 2011 at 3:02 AM, Christian Schneider wrote: > Hi Jeffrey, [...] > So if you only want one source of jms configuration then you best chance is > to use the camel config. On the other hand you can also have it redundant > and use properties for each param you want to configure. > > Ch

Re: Memory leak in camel mail component

2011-02-08 Thread Claus Ibsen
Ah Found a better solution. The fileName on the ftp uri supports the simple expression. So what you can do is >From a processor / bean where you compute the uri's for the recipient list you add those headers to pair the url setHeader("name1", "a.txt") setHeader("name2", "b.txt") setHeader("name3

Re: Camel 2.4 + Spring + JTA Tx Manager on Fuse ESB

2011-02-08 Thread Charles Moulliard
I have tried what you propose but the behavior is the same. No rollback occurs with the JTA Transaction manager. Is it a config issue or anything else ... ? Do I have to setup a XA driver in this case ? On Tue, Feb 8, 2011 at 3:11 PM, Christian Schneider wrote: > Have you tried without the doTry

How to extend the Spring DSL ?

2011-02-08 Thread sebastien.petrucci
Hi gurus, I am currently developing some specific extensions for Camel. Today, it looks like that: (declaring spring bean using custom XML) To make it easier for my customers, I would like to extend the Spring DSL and end up with something like that: I spent som

Re: Memory leak in camel mail component

2011-02-08 Thread Claus Ibsen
On Tue, Feb 8, 2011 at 3:34 PM, Marco Crivellaro wrote: > > my list of recipients might contain several endpoints which does not > necessarily make use of the same fileName for the current message so adding > a processor/bean before the recipientList won't work (file name header > should be unique

Re: Camel 2.4 + Spring + JTA Tx Manager on Fuse ESB

2011-02-08 Thread Charles Moulliard
The same example works pretty fine using a Spring JPA TX manager with do try in camel. But I will try what you propose with JTA. On Tue, Feb 8, 2011 at 3:11 PM, Christian Schneider wrote: > Have you tried without the doTry and doCatch? > > I thought that the default behaviour would be to rollback

Re: Memory leak in camel mail component

2011-02-08 Thread Marco Crivellaro
my list of recipients might contain several endpoints which does not necessarily make use of the same fileName for the current message so adding a processor/bean before the recipientList won't work (file name header should be unique for each endpoint). would it be feasibel to add an interceptSend

Re: Memory leak in camel mail component

2011-02-08 Thread Claus Ibsen
On Tue, Feb 8, 2011 at 10:55 AM, Marco Crivellaro wrote: > > Thank you for your reply, > > > I can see a lot of org.apache.camel endpoints, I guess these are related to > the fact we are sending a huge number of file having a unique file name and > having the fileName option in the URI is making u

Re: Camel 2.4 + Spring + JTA Tx Manager on Fuse ESB

2011-02-08 Thread Christian Schneider
Have you tried without the doTry and doCatch? I thought that the default behaviour would be to rollback in case of an exception. Christian Am 08.02.2011 14:58, schrieb Charles Moulliard: Hi, I have setup camel route with mode to perform rollback on Fuse ESB 4.3. Here is the route def.

Camel 2.4 + Spring + JTA Tx Manager on Fuse ESB

2011-02-08 Thread Charles Moulliard
Hi, I have setup camel route with mode to perform rollback on Fuse ESB 4.3. Here is the route def.

Re: Multicast not enabling stream caching by default

2011-02-08 Thread Claus Ibsen
Hi We dont wanna enable stream caching automatic under the covers. You may also want to enable it if you use error handling with redelivery enabled etc. So there are more use cases. It's easy to enable as its just 1 switch on the camel context, or you can enable it on a per route basis. On Tue

Re: Multicast not enabling stream caching by default

2011-02-08 Thread adamcooney
You're right, I misread the 'Implicitly enabled for multicast and dead letter channel (Camel 1.x)' section of the page as overriding the camel 2 default but it was only in camel 1. It says the reason it was changed was to not change the payload under the covers, but since the purpose of multicast

Re: Multicast not enabling stream caching by default

2011-02-08 Thread Claus Ibsen
Where do you read that? The wiki page says that stream caching is disabled from Camel 2.0 onwards http://camel.apache.org/stream-caching.html In Camel 2.0 stream cache is default disabled out of the box. In Camel 1.x stream cache is default enabled out of the box. On Tue, Feb 8, 2011 at 11:43 A

Multicast not enabling stream caching by default

2011-02-08 Thread adamcooney
I've had a problem whereby I was trying to read an XML message in a multicast. The first recipient could read the XML stream but when the second recipient tried to read the XML stream the stream was null. After searching the Internet, I found documentsation saying that camel caches the Exchange me

Re: Memory leak in camel mail component

2011-02-08 Thread Marco Crivellaro
Thank you for your reply, I can see a lot of org.apache.camel endpoints, I guess these are related to the fact we are sending a huge number of file having a unique file name and having the fileName option in the URI is making unique all those endpoints even though FTP server is always the same (

Re: ETL: how to monitor the end of processing ?

2011-02-08 Thread Xavier Coulon
Hi Claus, Yep, it works fine once the context is correctly configured ;-) I added context.getShutdownStrategy().setTimeout(60*10); in the createRouteBuilder() method. @Override protected RouteBuilder createRouteBuilder() throws Exception { return new RouteBuilder() {

Re: ETL: how to monitor the end of processing ?

2011-02-08 Thread Claus Ibsen
Hi Yeah just set a higher timeout on the shutdown strategy. You can access it from the CamelContext. It's 10 sec by default when using the Camel Test Kit. On Tue, Feb 8, 2011 at 10:24 AM, Xavier Coulon wrote: > > Hello, > > [Still working on the unit tests...] > > Here are some messages I get

Re: ETL: how to monitor the end of processing ?

2011-02-08 Thread Xavier Coulon
Hello, [Still working on the unit tests...] Here are some messages I get in the console during a test that reads 5K lines: Route: route1 suspended and shutdown deferred, was consuming from: Endpoint[file:///D:/tmp/data] 10:18:37.880 [Camel Thread 20 - ShutdownTask] INFO o.a.c.impl.DefaultShut

Re: Bug in camel-lucene component

2011-02-08 Thread Claus Ibsen
Hi I have created a ticket https://issues.apache.org/jira/browse/CAMEL-3640 On Thu, Feb 3, 2011 at 11:31 AM, Claus Ibsen wrote: > On Thu, Feb 3, 2011 at 11:28 AM, Peter Thygesen > wrote: >> When indexing using Lucene Component I get an exception: >> >> java.lang.ClassCastException: java.lang.B

Re: ETL: how to monitor the end of processing ?

2011-02-08 Thread Xavier Coulon
Hello Claus, Thank you for all those pointers, I'll have a look at them ! Best regards, Xavier -- View this message in context: http://camel.465427.n5.nabble.com/ETL-how-to-monitor-the-end-of-processing-tp3374562p3375521.html Sent from the Camel - Users mailing list archive at Nabble.com.

Re: JMSConfiguration - Camel vs CXF

2011-02-08 Thread Christian Schneider
Hi Jeffrey, as far as I know you can not reuse the cxf JmsConfiguration for camel. What you can do is use the camel transport for CXF to attach a CXF endpoint to a camel jms destination. If you need an example for this I can give you more infos. So if you only want one source of jms configu