Re: Reading a file using camel stream component

2015-07-24 Thread Claus Ibsen
Hi Just implemented this in CAMEL-9010 On Wed, Apr 22, 2015 at 5:49 PM, Claus Ibsen wrote: > Hi > > Yeah not sure how easy it is to add logic to detect when a file > rollover. Maybe it reads the first N bytes and make a hash or > something. And then if the retry do the same, and when the hash no

com.sun.org.apache.xerces.internal.dom.TextImpl cannot be cast to java.lang.String

2015-07-24 Thread Markus Eisele
Hi, I was trying to convert a bunch of //text() Nodes selected via XPath into a List and keep getting a ClassCastException. My input xml: 9781617290450 9780132360280 The route .setHeader("isbns", xpath("/order//isbn/text()")) .bean(orderService, "handleOrder(${header[isbns]})") The Bean Me

Re: action at the end of the split

2015-07-24 Thread Jakub Korab
To add to what Claus said, a good way to go about this without getting lost in end()s is to do whatever you are doing inside the splitter within a sub-route, i.e.: from(...) .split(body().tokenize("\n")).streaming() .to("direct:processLine") .end() .log("after splitting") f

Re: com.sun.org.apache.xerces.internal.dom.TextImpl cannot be cast to java.lang.String

2015-07-24 Thread Jakub Korab
Try setting the return type from the xpath expression: .setHeader("isbns", xpath("/order//isbn/text()", List.class)) Jakub On 24/07/15 13:05, Markus Eisele wrote: Hi, I was trying to convert a bunch of //text() Nodes selected via XPath into a List and keep getting a ClassCastException. My in

Re: com.sun.org.apache.xerces.internal.dom.TextImpl cannot be cast to java.lang.String

2015-07-24 Thread Markus Eisele
Same ClassCast Exception: java.lang.ClassCastException: com.sun.org.apache.xerces.internal.dom.TextImpl cannot be cast to java.lang.String Cheers, Markus On 24 July 2015 at 14:11, Jakub Korab wrote: > Try setting the return type from the xpath expression: > > .setHeader("isbns", xpath("/order//

Re: com.sun.org.apache.xerces.internal.dom.TextImpl cannot be cast to java.lang.String

2015-07-24 Thread Henryk Konsek
Hi Markus, Can you send us the full stack trace? Cheers! pt., 24.07.2015 o 14:31 użytkownik Markus Eisele napisał: > Same ClassCast Exception: > > java.lang.ClassCastException: > com.sun.org.apache.xerces.internal.dom.TextImpl cannot be cast to > java.lang.String > > Cheers, > Markus > > On 24

Re: com.sun.org.apache.xerces.internal.dom.TextImpl cannot be cast to java.lang.String

2015-07-24 Thread Claus Ibsen
On Fri, Jul 24, 2015 at 2:11 PM, Jakub Korab wrote: > Try setting the return type from the xpath expression: > > .setHeader("isbns", xpath("/order//isbn/text()", List.class)) > I wonder if a xpath with /text() works for a NodeList type, eg you will end up with a NodeList of 2 text values. Though

Re: com.sun.org.apache.xerces.internal.dom.TextImpl cannot be cast to java.lang.String

2015-07-24 Thread Markus Eisele
Hi, here's the complete Stacktrace. @Claus: Agree. Sort of felt natural for me. Really surprise to see this exception. Cheers, M ---: java.lang.ClassCastExceptio

Bug: HazelcastIdempotentRepository::confirm should check useRecovery before using persistedCache

2015-07-24 Thread Dario Cimafonte
Hi all, I'm seeing a NullPointException at org.apache.camel.processor.aggregate.hazelcast.HazelcastAggregationRepository:362 I'm using "useRecovery=false". Camel version: 2.15.2 Environment: Apache ServiceMix 6.0.0 Component: camel-hazelcast-2.15.2.jar Regards, Dario Cimafonte

Invalid property 'sendTimeout' of bean class ActiveMQConnectionFactory

2015-07-24 Thread markmueller
Folks, Just to give you context for my problem, I'm trying to test exception handling when attempting to post to a queue which is full and not accepting any more messages. I created an ActiveMQ queue with 'storeUsageHighWaterMark="1"' and posted to the queue until it wouldn't take any more messag

Re: Bug: HazelcastIdempotentRepository::confirm should check useRecovery before using persistedCache

2015-07-24 Thread Claus Ibsen
Hi Yeah that is a little bug. You are welcome to log a JIRA and/or contribute a PR. It seems like there should be a if guard On Fri, Jul 24, 2015 at 7:04 PM, Dario Cimafonte wrote: > Hi all, > > I'm seeing a NullPointException at > org.apache.camel.processor.aggregate.hazelcast.HazelcastAggreg

Re: action at the end of the split

2015-07-24 Thread Wilson MacGyver
ah yes, that is one approach I tried. I think I may have found a problem, I'm going to work on creating a small reproducible test. Thanks On Fri, Jul 24, 2015 at 8:06 AM, Jakub Korab wrote: > To add to what Claus said, a good way to go about this without getting > lost in end()s is to do whatev

Placing and referencing DTO via exchange properties

2015-07-24 Thread Craig Taylor
I'm attempting the following route given a TestDTO implemented which has a constructor / getter / setter for a name property: from ("direct:testDTO") .setProperty("testDTO",bean(testDTO)) .to("direct:testDTO2"); from ("direc

Re: Placing and referencing DTO via exchange properties

2015-07-24 Thread Craig Taylor
Please ignore - problem ended up being that the @Before was not being called prior to the createRouteBuilder() within CamelTestSupport. This is w/ Camel-Test 2.8.1. Not sure that should be expected behavior but I've gotten around the issue by initializing it w/ in the createRouteBuilder. On Fri

Camel Exchange Properties when using Dead Letter Channel

2015-07-24 Thread SteveR
I have a Linux Java7 stand-alone application using Camel 2.14. I'm using the DLC pattern to capture exchanges to a local file when re-delivery attempts have been exhausted, based on my *delayPattern*. I'm also specifying the *useOriginalMessage *option. My goal is to compose another route that I

Re: Camel Netty (producer) - Doesn't throw Exception in case Server closes the connection

2015-07-24 Thread V4Vaithi
Tried using Camel 2.15 with netty 2.15 Issue is not resolved. :( -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Netty-producer-Doesn-t-throw-Exception-in-case-Server-closes-the-connection-tp5769603p5769895.html Sent from the Camel - Users mailing list archive at Nabbl