Re: Keep the lastModified timestamp when writing a file.

2010-01-13 Thread Claus Ibsen
On Thu, Jan 14, 2010 at 12:46 AM, sjmcduf wrote: > > I do the following: > > > "ftp://t...@ftp.ttessier.ca/ftp.input?&recursive=true&binary=true&consumer.delay=1000";) >            .to("file://M:/FTP.INPUT/"); > > I would like to have my file in transfered and keeping their > lastModifiedTime. I w

Re: FTP assume directory do not have dot

2010-01-13 Thread Claus Ibsen
On Thu, Jan 14, 2010 at 12:25 AM, sjmcduf wrote: > > I have the following error: > > Caused by: java.lang.IllegalArgumentException: Only directory is supported. > Endpoint must be configured with a valid directory: ftp.test >        at > org.apache.camel.component.file.remote.RemoteFileEndpoint.cr

Re: pojo example fails to build with ant

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 9:03 PM, NP-Hard wrote: > > Well that message was the warning; here is the full log from the console > window: > - > Buildfile: build.xml > > build.classes: > > build.test: > > build: > > run: >     [java] [                  

Re: Camel 1.6 and Spring 3

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 10:47 PM, efender wrote: > > Spring's ServerSessionFactory has been removed in Spring 3. > > There's a related issue that made it in to 2.0. > http://issues.apache.org/activemq/browse/CAMEL-502 > > It seems that the changes to JmsConfiguration and JmsComponent from that > i

Keep the lastModified timestamp when writing a file.

2010-01-13 Thread sjmcduf
I do the following: "ftp://t...@ftp.ttessier.ca/ftp.input?&recursive=true&binary=true&consumer.delay=1000";) .to("file://M:/FTP.INPUT/"); I would like to have my file in transfered and keeping their lastModifiedTime. I wonder if a flag is available for that ? Another solu

FTP assume directory do not have dot

2010-01-13 Thread sjmcduf
I have the following error: Caused by: java.lang.IllegalArgumentException: Only directory is supported. Endpoint must be configured with a valid directory: ftp.test at org.apache.camel.component.file.remote.RemoteFileEndpoint.createConsumer(RemoteFileEndpoint.java:68) at org.apach

Re: Camel and JMS Client Ack Mode?

2010-01-13 Thread MikeBAH
Just an FYI I am using Camel 2.1 Thanks -- View this message in context: http://old.nabble.com/Camel-and-JMS-Client-Ack-Mode--tp27152146p27153467.html Sent from the Camel - Users mailing list archive at Nabble.com.

Camel 1.6 and Spring 3

2010-01-13 Thread efender
Spring's ServerSessionFactory has been removed in Spring 3. There's a related issue that made it in to 2.0. http://issues.apache.org/activemq/browse/CAMEL-502 It seems that the changes to JmsConfiguration and JmsComponent from that issue should be (almost) enough to get this working correctly. H

Camel and JMS Client Ack Mode?

2010-01-13 Thread MikeBAH
I am trying out Camel for use in a project. One of the things we would like to do is have guaranteed delivery. To that end I am trying to use Client Ack mode in JMS to leave a message on the Queue I read it from until all the processing has been completed. This is similar to what was asked in

Re: pojo example fails to build with ant

2010-01-13 Thread NP-Hard
Well that message was the warning; here is the full log from the console window: - Buildfile: build.xml build.classes: build.test: build: run: [java] [ main] MainSupport INFO Apache Camel 2.1.0 s

Re: Intercept a processor?

2010-01-13 Thread Johan Haleby
That looks really neat and would as far as I can see really help. It would be simple for me to wrap this in a test base class exposing something like "awaitCompletion("direct:foo")". Would be desirable/possible to have something similar to modify or extend an already defined route? Something lik

Re: Workaround for PropertyPlaceholderConfigurer and packageScan?

2010-01-13 Thread Johan Haleby
I've added jira ticket https://issues.apache.org/activemq/browse/CAMEL-2358 2358 . Thanks! Claus Ibsen-2 wrote: > > Hi > > On Tue, Jan 12, 2010 at 7:16 PM, Johan Haleby > wrote: >> >> Hi, >> >> I've read the FAQ and I understand that I cannot use the placeholders in >> inside the Camel XML i

Re: camel-cache: Using Objects for cache

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 7:19 PM, tide08 wrote: > > Thanks Claus! ArtifactID says springsource is it some customized version of > ehCache we are using? Reason I am asking is that I have conflict with > hibernate and I need to exclude ehCache dependency from either one of these. > Its the OSGi prob

Re: pojo example fails to build with ant

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 7:17 PM, NP-Hard wrote: > > Thanks for the response. That got me past the first issue and now I get: >   Cannot find class: org.apache.xalan.xsltc.trax.DOM2SAX > > I don't see an obvious jar that has xalan in the camel distribution; do I > need to download > it separately a

Re: camel-cache: Using Objects for cache

2010-01-13 Thread tide08
Thanks Claus! ArtifactID says springsource is it some customized version of ehCache we are using? Reason I am asking is that I have conflict with hibernate and I need to exclude ehCache dependency from either one of these. Also, I had another suggestion for cache component: - Clean up ehCache.xm

Re: pojo example fails to build with ant

2010-01-13 Thread NP-Hard
Thanks for the response. That got me past the first issue and now I get: Cannot find class: org.apache.xalan.xsltc.trax.DOM2SAX I don't see an obvious jar that has xalan in the camel distribution; do I need to download it separately and add it to the classpath in common_build.xml ? Thanks.

Re: Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Attilio Donà
Claus, I've tried the 2.2-SNAPSHOT (svn co https://svn.apache.org/repos/asf/camel/trunk camel) and the problem persist: I've also problems with the mvn install (2 test fails) and finally also skipping the tests I got a lot of WARNING and an ERROR: [WARNING] Warning building bundle org.ap

Re: recipientList retryUntil not working?

2010-01-13 Thread Claus Ibsen
Hi Can you try moving the onException on up? And if still a problem then try using onException as context scoped, eg outside the from Just to see if that resolves anything. I am a tad busy with a couple of other issues, but let me know how goes. And if still a problem then create a JIRA so we c

Re: Intercept a processor?

2010-01-13 Thread Claus Ibsen
Hi I think CAMEL-2357 is what you are looking for https://issues.apache.org/activemq/browse/CAMEL-2357 If you could take a look and maybe if you got some ideas or how you would like the API to be to support your use-case. There are some code snippets of my prototype in there. On Wed, Jan 13, 20

Re: Rss Feed route config

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 4:59 PM, user09772 wrote: > > This is what I thought I was doing: > >    from("rss:myRssFeedURI").marshal().rss().to("direct:simple-rss-send"); >    from("direct:simple-rss-send").process(new Processor() { >            public void process(Exchange e) { >                LOG.

Re: more samples please!

2010-01-13 Thread James Carr
Thanks... this solved a small problem I was having. :) On Wed, Jan 13, 2010 at 7:54 AM, Willem Jiang wrote: > You can also try out camel-servlet component[1]. > Please make sure the CamelHttpTransportServlet is loaded before the > camelcontext is started. > > [1] http://camel.apache.org/servlet.h

Re: Rss Feed route config

2010-01-13 Thread user09772
This is what I thought I was doing: from("rss:myRssFeedURI").marshal().rss().to("direct:simple-rss-send"); from("direct:simple-rss-send").process(new Processor() { public void process(Exchange e) { LOG.info("Received exchange: " + e.getIn()); }

recipientList retryUntil not working?

2010-01-13 Thread mcrive
I have following route: from("jms-test:queue:queue.delivery.notification.test") .process(processor) .onException(Exception.class).retryUntil(bean("myRetryBean")).end() .recipientList(header("recipientListHeader").tokenize(",")) .parallelProcessing().e

Re: more samples please!

2010-01-13 Thread Willem Jiang
You can also try out camel-servlet component[1]. Please make sure the CamelHttpTransportServlet is loaded before the camelcontext is started. [1] http://camel.apache.org/servlet.html Willem moller wrote: moller wrote: I'm looking for a sample that uses spring+camel+webcontainer (tomcat).

Re: Intercept a processor?

2010-01-13 Thread Willem Jiang
Johan Haleby wrote: Hi, Thank you very much your suggestion with event notifiers worked! But I hope the changes in 2.2 can make it even better since now the ExchangeCompletedEvent is sent several times (once per "from" in the route definition") and thus it's hard to know the count in the latch w

Re: more samples please!

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 2:22 PM, moller wrote: > > > moller wrote: >> >> I'm looking for a sample that uses spring+camel+webcontainer (tomcat). The >> idea is to consume the incoming http request and route it to a file. Does >> anyone have a fully working sample that can be build and runs on tomca

Re: more samples please!

2010-01-13 Thread moller
moller wrote: > > I'm looking for a sample that uses spring+camel+webcontainer (tomcat). The > idea is to consume the incoming http request and route it to a file. Does > anyone have a fully working sample that can be build and runs on tomcat > > See the nice picture on: > http://activemq.apach

Re: recipientList redelivery

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 1:02 PM, mcrive wrote: > > I think there is a small in the documentation > > In Errors Handlers features it is listed "redeliverUntil" > http://camel.apache.org/error-handler.html > while the feature seems to be named "retryUntil" > http://camel.apache.org/exception-clause.

Re: Retrieving MailMessage bodies as DataHandler objects

2010-01-13 Thread Willem Jiang
Hi, Camel Message has getAttachements() method which can help you get the DataHandlers. You can find the unit test of camel-mail here[1] [1] https://svn.apache.org/repos/asf/camel/trunk/components/camel-mail/src/test/java/org/apache/camel/component/mail/MailAttachmentTest.java Willem huntc

Re: recipientList redelivery

2010-01-13 Thread mcrive
I think there is a small in the documentation In Errors Handlers features it is listed "redeliverUntil" http://camel.apache.org/error-handler.html while the feature seems to be named "retryUntil" http://camel.apache.org/exception-clause.html Claus Ibsen-2 wrote: > > No you should not. Use the

How to Understand InOnly and InOut pattern

2010-01-13 Thread ext2
While learning camel's pattern, it seems the in only patter is very hard to understand; Following is a test-case from the camel's unit test( with a little change). inProcess bean just increase the input message body(as Integer) and set back to input message. outProcess bean just increase the inpu

Re: recipientList redelivery

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 12:49 PM, mcrive wrote: > > > Claus Ibsen-2 wrote: >> >> You can use redeliverUntil to determine whether or not redelivery should >> occur. >> >> And you can get the failed endpoint as a property: >> String failedEndpointUri = >> exchange.getProperty(Exchange.FAILURE_ENDPOI

Re: Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 11:28 AM, Attilio Donà wrote: > > > Just to add some more information: > > The previous stack trace is obtained with a java 6 environment. > If I switch to a java 5 the result is different (probably the cause is the > same), see the attached output below. > > Just a composi

Re: recipientList redelivery

2010-01-13 Thread mcrive
Claus Ibsen-2 wrote: > > You can use redeliverUntil to determine whether or not redelivery should > occur. > > And you can get the failed endpoint as a property: > String failedEndpointUri = > exchange.getProperty(Exchange.FAILURE_ENDPOINT, String.class); > > Then in your redeliverUntil you ca

Re: How to inject a custom ManagedProcessor into camel?

2010-01-13 Thread Claus Ibsen
Hi I cannot recall whether custom Processor can be managed out of the box. Its meant for components, endpoints etc. What you need is to implement the ManagementAware in your custom Processor. See more here: (in the bottom) http://camel.apache.org/camel-jmx.html I will later cover such a scenari

Re: Intercept a processor?

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 9:11 AM, Johan Haleby wrote: > > Hi, > > Thank you very much your suggestion with event notifiers worked! But I hope > the changes in 2.2 can make it even better since now the > ExchangeCompletedEvent is sent several times (once per "from" in the route > definition") and th

Re: Retrieving MailMessage bodies as DataHandler objects

2010-01-13 Thread Claus Ibsen
Hi You can get access to the underlying javax.mail.Message https://svn.apache.org/repos/asf/camel/trunk/components/camel-mail/src/main/java/org/apache/camel/component/mail/MailMessage.java javax.mail.Message mailMessage = exchange.getIn(MailMessage.class).getMessge(); And maybe there is a type c

Re: recipientList redelivery

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 12:28 PM, mcrive wrote: > > hi I am using Camel 2.2, > is there a way to specify a different value of maximumRedeliveries for each > endpoint when using recipentList? > You can use redeliverUntil to determine whether or not redelivery should occur. And you can get the fai

recipientList redelivery

2010-01-13 Thread mcrive
hi I am using Camel 2.2, is there a way to specify a different value of maximumRedeliveries for each endpoint when using recipentList? -- View this message in context: http://old.nabble.com/recipientList-redelivery-tp27143430p27143430.html Sent from the Camel - Users mailing list archive at Na

Retrieving MailMessage bodies as DataHandler objects

2010-01-13 Thread huntc
Hi there, Supposing that I receive an Exchange using Camel Mail and I want to see whether the body is of the required MIME type; is it valid to do this: // See if our exchange body contains the calendar object. DataHandler bodyDataHandler = exchange.getIn().getBody( DataHandl

Re: Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Attilio Donà
Just to add some more information: The previous stack trace is obtained with a java 6 environment. If I switch to a java 5 the result is different (probably the cause is the same), see the attached output below. Just a composite question, have you tried the camel-example-spring-jms in the camel

Re: Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Attilio Donà
The activemq-core-5.3.0.jar (where the schema is located) is on the list: [INFO] The following files have been resolved: [INFO]aopalliance:aopalliance:jar:1.0:compile [INFO]asm:asm:jar:3.1:compile [INFO]cglib:cglib-nodep:jar:2.1_3:compile [INFO]com.sun.jersey:jersey-atom:jar:1.1

Re: Retrieve BrokerName & Velocity

2010-01-13 Thread Willem Jiang
Sorry, I don't think camel find the BrokerName itself. Maybe you need to try use the property placeholder and pass this setting into the camel route, and let the camel route set the message header for you. Willem titexe wrote: I seek to recover the value BrokerName "LAPTOP" which is defined

Re: Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Willem Jiang
Please use mvn depedency:list to check if there is a camel-core 5.3.0.jar in the list. Spring supports to load the schema from class path. Willem Attilio Donà wrote: Yes, I can Attilio Claus Ibsen-2 wrote: Hi And you can read this url from a web browser? http://activemq.apache.org/schema

Re: Retrieve BrokerName & Velocity

2010-01-13 Thread titexe
I seek to recover the value BrokerName "LAPTOP" which is defined in the file activemq.xml http://activemq.apache.org/schema/core"; brokerName="LAPTOP" dataDirectory="${activemq.base}/data"> there's any way to retrieve this value with a component Camel? Thanks in advance, titexe willem.jiang

Re: Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Attilio Donà
If you look at the exception message, the point 3: 3) the root element of the document is not Is matched: the root element of http://activemq.apache.org/schema/core/activemq-core-5.3.0.xsd is . I suspect it is something related to xbean but I don't know how to solve the configuration problem.

Re: Question about multicasting.

2010-01-13 Thread ztesoft
Claus Ibsen-2 wrote: > > Hi > > If you want to return a response immediately from the webservice, you > can break up the route into 2 pieces. > > For example you can use the wire tap EIP pattern > http://camel.apache.org/wire-tap.html > > from(cxf) > wireTap(direct:b) > transform(constan

Re: Workaround for PropertyPlaceholderConfigurer and packageScan?

2010-01-13 Thread Claus Ibsen
Hi On Tue, Jan 12, 2010 at 7:16 PM, Johan Haleby wrote: > > Hi, > > I've read the FAQ and I understand that I cannot use the placeholders in > inside the Camel XML in a spring configuration. However I've seen > workarounds for uri's by defining endpoints outside of the camel context xml > configu

Re: Question about multicasting.

2010-01-13 Thread Claus Ibsen
Hi If you want to return a response immediately from the webservice, you can break up the route into 2 pieces. For example you can use the wire tap EIP pattern http://camel.apache.org/wire-tap.html from(cxf) wireTap(direct:b) transform(constant("some reply")); from(direct:b) multicast O

Re: Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Attilio Donà
Yes, I can Attilio Claus Ibsen-2 wrote: > > Hi > > And you can read this url from a web browser? > http://activemq.apache.org/schema/core/activemq-core-5.3.0.xsd > > > > On Wed, Jan 13, 2010 at 9:45 AM, Attilio Donà > wrote: >> >> Camel version: 2.1.0 >> >> The camel-example-spring-jms e

Re: Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Claus Ibsen
Hi And you can read this url from a web browser? http://activemq.apache.org/schema/core/activemq-core-5.3.0.xsd On Wed, Jan 13, 2010 at 9:45 AM, Attilio Donà wrote: > > Camel version: 2.1.0 > > The camel-example-spring-jms example doesn't work (the internet connection > is up): > > I have the

Camel 2.1.0 camel-example-spring-jms does not work

2010-01-13 Thread Attilio Donà
Camel version: 2.1.0 The camel-example-spring-jms example doesn't work (the internet connection is up): I have the same error in my Camel project, where I cloned the example configuration. Thanks in advance Attilio To reproduce the problem: mvn compile mvn exec:java -PCamelServer The result

Re: Question about multicasting.

2010-01-13 Thread ztesoft
I find soapUI waited for the http reply after it sent the request until the program ended. The solution is let the camel reply. Just add the code "e.getOut().setBody("I received HTTP request");" into the process block. Then soapUI can get the reply after it sends the request. Do I walk a right

Re: Question about multicasting.

2010-01-13 Thread Claus Ibsen
On Wed, Jan 13, 2010 at 8:07 AM, ztesoft wrote: > > This method "seems" like solve the problem. > But, I find soapUI waited for the http reply after it sent the request until > the program ended. > Maybe this is another topic about how to handle the request and reply. Does > anyone know it? > Also

Re: Camel : Date Pattern

2010-01-13 Thread titexe
This date format is the XML date format: The dateTime XML is specified in the following form "-MM-DDThh: mm: ss" Claus Ibsen-2 wrote: > > Hi > > Check ticket > https://issues.apache.org/activemq/browse/CAMEL-2353 > > On Wed, Jan 13, 2010 at 6:37 AM, Claus Ibsen > wrote: >> Hi >> >> The

Re: Intercept a processor?

2010-01-13 Thread Johan Haleby
Hi, Thank you very much your suggestion with event notifiers worked! But I hope the changes in 2.2 can make it even better since now the ExchangeCompletedEvent is sent several times (once per "from" in the route definition") and thus it's hard to know the count in the latch when you're not sure t