Re: Camel mina : data truncated to 1024 bytes

2013-03-07 Thread nil
We finally find the problem which was in our ProtocolEncoder implementation. In fact, the doDecode was reading just 1024 first bytes in the ByteBuffer whereas our frame (which know its length) was indicating more bytes. To prevent that, we resume reading in IoSession and returns false in doDocode i

Re: Camel mina : data truncated to 1024 bytes

2013-03-07 Thread Christian Müller
Did you already checked this test: https://svn.apache.org/repos/asf/camel/trunk/components/camel-mina/src/test/java/org/apache/camel/component/mina/MinaVMCustomCodecTest.java And there are much more: https://svn.apache.org/repos/asf/camel/trunk/components/camel-mina/src/test/java/org/apache/camel/c

Re: Camel mina : data truncated to 1024 bytes

2013-03-07 Thread Christian Müller
Which codec factory do you use (you didn't show us the configuration)? TextLineCodecFactory? -> encoderMaxLineLength/decoderMaxLineLength are applied. ObjectSerializationCodecFactory? -> encoderMaxLineLength/decoderMaxLineLength are *NOT* applied. A custom? Best, Christian On Thu, Mar 7, 2013 at

Re: camel-smpp optional param issue ?

2013-03-07 Thread Christian Müller
Update: CAMEL-6116 is fixed. Will work on CAMEL-6121 in the next days... Best, Christian On Wed, Mar 6, 2013 at 5:07 PM, Christian Müller < christian.muel...@gmail.com> wrote: > Will have look at the patch later today... > > Sent from a mobile device > Am 06.03.2013 05:35 schrieb "anuragg" : > >

Re: Camel multiple (nested) routes in one context

2013-03-07 Thread Christian Müller
Can you try Camel 2.10.4? http://camel.apache.org/download.html Best, Christian On Wed, Mar 6, 2013 at 10:15 AM, ddewaele wrote: > Hi, > > We're using 2.10.1. > > Any idea about the logging (don't know if this is related) ? The fact that > it added "complex-route" instead of "main-route" in th

Re: AWS S3 Request/Reply

2013-03-07 Thread Christian Müller
Hello Daniel, please find my comments inline. Best, Christian On Tue, Mar 5, 2013 at 4:52 PM, json99 wrote: > Hi, > > I'm trying to build a cloud enabled Camel client. To be able to transfer > large files (>65k) I first create a AWS S3 file with a UUID as filename. To > be able to process the

Re: How to get response from activeMQ when a message is put on queue?

2013-03-07 Thread Christian Müller
Try Best, Christian On Thu, Mar 7, 2013 at 3:42 PM, jrpedersen wrote: > Hi, > I am trying to use Camel (mina, jms) where I receive messages on a tcp > port, > using mina, and decode the message before it is put on a activemq queue. > I want to send a ack on tcp if the message is s

Re: Enable wire logs on Camel HTTP Proxy

2013-03-07 Thread Willem jiang
Hi As you are using Servlet transport, I think you may consider to setup the log of web container. They you can get to whole picture of wire HTTP logs between the client and Camel Proxy. -- Willem Jiang Red Hat, Inc. FuseSource is now part of Red Hat Web: http://www.fusesource.com | http://

Re: Write enriched data after a split in a file

2013-03-07 Thread Willem jiang
Can you try to use the aggregator to put the transformed objects together before sending it to the file ? -- Willem Jiang Red Hat, Inc. FuseSource is now part of Red Hat Web: http://www.fusesource.com | http://www.redhat.com Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.c

Re: Viewing the contents of camel-cache

2013-03-07 Thread Willem jiang
camel-cache just let you know the change of the cache and help you change the content of the cache. If you want to read the content of the cache, you can use the ehcache API to access the cache content[1] [1]http://ehcache.org/documentation/code-samples#using-caches -- Willem Jiang Red Hat

Re: Enable wire logs on Camel HTTP Proxy

2013-03-07 Thread rouble
Willem, Scott, Claus et al, Appreciate all your input. So, is there no "camel way" to get the logs from the client to the camel proxy? Or do I have to look at the web container (tomcat or Jetty) logs? Here is my topology: Client<>Camel Proxy<>Remote Endpoint And my simple route:

Re: Update database using Java DSL JPA

2013-03-07 Thread Baalu
Are you asking to do something like this: from("jpa1://Entity1") bean:beanName[?method=someMethod] .to("jpa1://Entity2") If possible can you tell me the actual flow... I have Entity1 and Entity2, I need to access Entity1, get a value of a column from Entity1 based on a criteria then take th

Re: How to know if a component is InOnly by default

2013-03-07 Thread Hadrian Zbarcea
The route MEP is ignored by almost all the components and almost useless. So you can get it from the exchange, but it won't help you much. You need to read the doc for the components you're using and understand what they do given the uri configuration you used. My $0.02, Hadrian On 03/07/20

Re: SEDA and DIRECT route does not propagate back the exception to the calling route

2013-03-07 Thread ODarwish
the problem fixed by creating no error handler and refernce it in the sub routes ,then the exception back to the calling route - Othman Darwish ProgressSoft Corp. -- View this message in context: http://camel.465427.n5.nabble.com/SEDA-and-DIRECT-route-does-not-propagate-back-the-excep

Re: Quartz component question

2013-03-07 Thread Claus Ibsen
On Mon, Mar 4, 2013 at 9:21 PM, Larry Meadors wrote: > I have a weekly data export that uses a quart timer defined like this: > > quartz://circVendorRoyaltyTimer?cron=0+0+1+?+*+SAT+* > > The timer sends a message to a route that in turn sends a message with > a date range in it to another route th

Re: Suspending route/context if one component can't process messages

2013-03-07 Thread Claus Ibsen
Hi Yeah you can implement a custom PollingConsumerPollingStrategy http://camel.apache.org/polling-consumer.html And then suspend/stop the consumer if it has failed to often. On Wed, Mar 6, 2013 at 5:15 PM, DOLECEK Ales wrote: > Hello, > > I have endpoints that communicate with 3rd party prop

Re: Camel blueprint and drools

2013-03-07 Thread Claus Ibsen
On Thu, Mar 7, 2013 at 2:04 PM, AlanFoster wrote: > Hi Claus, > > Thanks for the response; > > I spotted this example before, but unfortunately the spring example doesn't > work when trying to convert it to a blueprint bundle > > Do you happen to know where a blueprint bundle example can be found?

Re: How to get response from activeMQ when a message is put on queue?

2013-03-07 Thread Claus Ibsen
On Thu, Mar 7, 2013 at 3:42 PM, jrpedersen wrote: > Hi, > I am trying to use Camel (mina, jms) where I receive messages on a tcp port, > using mina, and decode the message before it is put on a activemq queue. > I want to send a ack on tcp if the message is succesfully added to the queue > or a na

Re: Update database using Java DSL JPA

2013-03-07 Thread Claus Ibsen
On Tue, Mar 5, 2013 at 9:55 PM, Baalu wrote: > I looked at your example and it used Camel 2.11, but we are using 2.10.3 > where we dont have a hibernate component. > > We are using JPA component, is there any way we can use consumer.query or > consumer.nativequery or a namedquery on it to update t

Re: How to get response from activeMQ when a message is put on queue?

2013-03-07 Thread ODarwish
hi you can add exception handler on route or context scope to send the nac reply , as for ack after sending the jms you can create the ack message and post it to tcp point e.g . from direct {onexception create nak response ,attach it to exchange body to tcp } to jms ceate ack response and

Re: Camel mina : data truncated to 1024 bytes

2013-03-07 Thread nil
Hi, Thanks for reply. However, I don't see how to set this property in my app. We effectively have a custom codec We try to extends our codec factory with TextLineDecoder to override

Re: Enrich with data from SQL

2013-03-07 Thread Jean Francois LE BESCONT
I have found a solution I will post a whole example when every thing will work in my project. 2013/3/7 Jean Francois LE BESCONT > Thanks for all these explictions ! Hope I will give back my knowledge when > I will have enough camel knowledge :) > > With filter, I goto my enrich only for the f

SEAD and DIRECT route does not propagate back the exception to the calling route

2013-03-07 Thread ODarwish
SEAD and DIRECT route does not propagate back the exception to the calling route If I have route1 which has exception handling block defined at route scope , when I call route 2 using seda or direct point and exception generated for any reason inside route 2,this exception does not propagated b

Re: Camel blueprint and drools

2013-03-07 Thread AlanFoster
Hi Claus, Thanks for the response; I spotted this example before, but unfortunately the spring example doesn't work when trying to convert it to a blueprint bundle Do you happen to know where a blueprint bundle example can be found? :) Alan Claus Ibsen-2 wrote > Hi > > There is a Camel and

Re: Camel blueprint and drools

2013-03-07 Thread Claus Ibsen
Hi There is a Camel and Drools example here https://github.com/FuseByExample/camel-drools-example On Thu, Mar 7, 2013 at 1:03 PM, AlanFoster wrote: > Hi all, > > Just wondering if there's any examples of drools running under blueprint? > > I can see that there is a camel-spring example, which w

Camel blueprint and drools

2013-03-07 Thread AlanFoster
Hi all, Just wondering if there's any examples of drools running under blueprint? I can see that there is a camel-spring example, which works great, but not a camel-blueprint example anywhere I'd appreciate if anyone knows anything about this :) Thanks, Alan -- View this message in context:

Re: Files cannot be moved on FTP

2013-03-07 Thread Claus Ibsen
On Wed, Mar 6, 2013 at 12:05 PM, Lutter, Robin wrote: > Hi Claus, > > we use ftp. Setting separator to UNIX doesn't help. Contrary the error > occurs earlier in process: > > WARN org.apache.camel.component.file.GenericFileOnCompletion - Caused > by: [org.apache.camel.component.file.GenericFileOpe

Re: Camel XQuery - Saxon

2013-03-07 Thread Claus Ibsen
On Wed, Mar 6, 2013 at 2:29 AM, Raul Kripalani wrote: > I suppose this declares the namespaces through the StaticContext. But > according to the XQuery spec, declaring them in the Prolog (leading section > of the XQuery expression file) should have the same effect. And it's easier > to maintain in

Re: File component/language: preMove only

2013-03-07 Thread Claus Ibsen
On Wed, Mar 6, 2013 at 6:40 AM, vss123 wrote: > Sorry. The Camel version we use is 2.10.3. > > We have a drop-zone in a file system where the other systems drop xml files. > > With this project we use camel to pickup these files and do processing to > communicate with few other systems. We want to

Re: camel-blueprint-test issues

2013-03-07 Thread Claus Ibsen
On Sun, Mar 3, 2013 at 2:38 PM, Ryan Moquin wrote: > This fix would be in a snapshot by now right? Just want to make sure I > try it against a corrected snapshot. > Yeah you can see on the timestamp on the SNAPSHOT JAR being downloaded. Though you can build the source yourself and use that htt

Re: Camel mina : data truncated to 1024 bytes

2013-03-07 Thread nil
I forget to tell that i'm using camel 2.10.0 Thanks -- View this message in context: http://camel.465427.n5.nabble.com/Camel-mina-data-truncated-to-1024-bytes-tp5728733p5728735.html Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Camel mina : data truncated to 1024 bytes

2013-03-07 Thread Claus Ibsen
Hi What Camel version do you use? I think when you use a custom codec, eg myCodecFactory Then you need to handle the line length in your codec. I think encoderMaxLineLength is only in use when using the out of box textline codec. On Thu, Mar 7, 2013 at 11:40 AM, nil wrote: > Hi, > > I'm using

Camel mina : data truncated to 1024 bytes

2013-03-07 Thread nil
Hi, I'm using camel mina component configured like this : My problem is data are always truncated to 1024 first bytes. I try using in my Mina Configuration but no effect. Is there something i'm doing wrong Thanks for your reply NIL -- View this message

Re: Using routing slip as work around to parameterize the end point URI

2013-03-07 Thread Claus Ibsen
On Wed, Mar 6, 2013 at 4:46 PM, ODarwish wrote: > recipient List or routing Slip will give the same result if we looking to > solve the daynamic URI issue right Claus ? > Yes, though with recipient list you do not need to set a header first. > > > > > - > Othman Darwish > ProgressSoft

Re: TransactionnalDeadLetterChannel ?

2013-03-07 Thread Claus Ibsen
On Thu, Mar 7, 2013 at 11:10 AM, valerian.merkling wrote: > Hi, > > My route read a file, parse the xml stuff inside, valid and transform it to > finally write it somewhere else. > > My goal is : on any unhandled error, rollback and redeliver up to X times, > every Y seconds and finally send the o

TransactionnalDeadLetterChannel ?

2013-03-07 Thread valerian.merkling
Hi, My route read a file, parse the xml stuff inside, valid and transform it to finally write it somewhere else. My goal is : on any unhandled error, rollback and redeliver up to X times, every Y seconds and finally send the original file on another queue. Right now, i've defined a deadLetterCh

Re: Enrich with data from SQL

2013-03-07 Thread Jean Francois LE BESCONT
Thanks for all these explictions ! Hope I will give back my knowledge when I will have enough camel knowledge :) With filter, I goto my enrich only for the first line of my file. .filter(simple("${property.CamelSplitIndex} == 0")) .enrich("direct:datasource", new AggregationEnrichissementZo

Re: Enrich with data from SQL

2013-03-07 Thread Thibault Cassan
Hi Claus, I am no specialist, but in your case, it would seem the enrichment will happen only on the first line of the csv, isn't it ? >From what I understood, Jean-François, would want to enrich each line, with the same data incoming from his database. What if he synchronizes two routes ? A first

Re: Enrich with data from SQL

2013-03-07 Thread Raul Kripalani
If you want to query the DB once, you should definitely restructure the route a bit. Here's the simplest option IMO. The goal is to query once and make the query result available to all split tasks: - Run bindy before the split, which will generate a List of AED objects. - Create a small bean tha

Re: Enrich with data from SQL

2013-03-07 Thread Claus Ibsen
On Thu, Mar 7, 2013 at 9:25 AM, Jean Francois LE BESCONT wrote: > Sorry if my explanation are not good ... :) > > I have a csv file. I would like to process this file to enrich with data > in sql table (then write enriched line in output). > > I process file with a binding in business class : >

Re: Enrich with data from SQL

2013-03-07 Thread Jean Francois LE BESCONT
Sorry if my explanation are not good ... :) I have a csv file. I would like to process this file to enrich with data in sql table (then write enriched line in output). I process file with a binding in business class : .from("file://mycsv.csv") .split() .tokenize("\n") .streaming() .unmarshal()

Re: how to get CamelContext using Spring

2013-03-07 Thread anver
Hi, Please give a "id" to the CamelContext. you can grab it using the Spring's getBean method. For example if you give the following camle context code inside your springs application context xml then you can get the "FIRST-CAMLE-CONTEXT" using the getBean() method http://camel.apache.org/sch