Exception when using FTP as endpoint
I have two camel routes. The first camel route takes input from JMS and sends to FTP location. Also, the first rotue sends that file to a seda location. This seda location is the input for the second route which again processes the file and sends it to the same FTP location. But when I run this route I get the following exception: *Writing file failed with: File operation failed: 530 Login authentication failed* My two routes look like this: from(fromLocation) .marshal().gzip() .to(toLocation) .to(seda:BillingSedaLocation+routeId); from(seda:BillingSedaLocation+routeId) .unmarshal().gzip() .process(new SomeProcessor()) .to(toLocation); The fromLocation is a jmsQueue and the toLocation is a FTP endpoint. -- View this message in context: http://camel.465427.n5.nabble.com/Exception-when-using-FTP-as-endpoint-tp5734270.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Regarding auto_delete_after
hi, I asked the question on activemq forum and they asked me to post the same on camel forum , so posting the same question here. I am using activemq with camel ,I have defined routes like : 1) from servletA to actimq A 2) from activemq A to servletB 3) from servletB to activemq C 4) from activemq C to servlet D during first time request, the activemq works fine, but if i send the request second time, I am getting following exceptions : javax.jms.IllegalStateException: The Consumer is closed org.apache.camel.RuntimeCamelException: org.springframework.jms.InvalidDestinationException: Cannot publish to a deleted Destination: org.apache.camel.ExchangeTimedOutException: The OUT message was not received within: 2 millis due reply message with correlationID... scenario is, not a single producer or consumer of routes are closed, but still m getting above exceptions. can anybody tell me the reason behind the exceptions. absolutely not able to find the cause. /*the reply that i got on activemq forum is :*/ It might be better to ask in the Camel mailing list. Post your camel route. But it sounds like somehow your consumers aren't cached propelry. *camel routes are as follows :* public void configure() { from(servlet:///servletA) .process(new Processor() { @Override public void process(Exchange exchange) throws Exception { System.out.println(*** from servletA to activemq inbox); } }) .to(activemq:queue:inbox); from(activemq:queue:inbox) .setHeader(Exchange.HTTP_METHOD, constant(POST)) .process(new Processor() { @Override public void process(Exchange exchange) throws Exception { System.out.println(*** from activemq inbox to applicationB); } }) .to (http://localhost:8082/applicationB/a.do?bridgeEndpoint=true;) .process(new Processor() { @Override public void process(Exchange exchange) throws Exception { System.out.println(*** from applicationB back to the caller that is servletA); exchange.getOut().setHeader(JOB_NO, exchange.getIn().getHeader(JOB_NO)); } }); from(servlet:///servletC) .process(new Processor() { @Override public void process(Exchange exchange) throws Exception { System.out.println(*** from servletC to activemq inboxD); } }) .to(activemq:queue:inboxD); from(activemq:queue:inboxD) .setHeader(Exchange.HTTP_METHOD, constant(POST)) .process(new Processor() { @Override public void process(Exchange exchange) throws Exception { System.out.println(*** from activemq inboxD to applicationE); } }) .to(ExchangePattern.InOnly,http://localhost:8082/applicationE/agentResp?bridgeEndpoint=true;); } -- View this message in context: http://camel.465427.n5.nabble.com/really-need-a-help-its-Regarding-auto-delete-after-tp5734164p5734271.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: consumer\producer only endpoint
The practice is to thrown an unsupported operation exception etc. On Tue, Jun 18, 2013 at 1:18 AM, javamonkey79 javamonke...@gmail.com wrote: With custom endpoints that have only a producer or only a consumer, do you just return null in the endpoint class, or is there something special you have to do? Thanks! -- View this message in context: http://camel.465427.n5.nabble.com/consumer-producer-only-endpoint-tp5734268.html Sent from the Camel - Users mailing list archive at Nabble.com. -- Claus Ibsen - www.camelone.org: The open source integration conference. Red Hat, Inc. FuseSource is now part of Red Hat Email: cib...@redhat.com Web: http://fusesource.com Twitter: davsclaus Blog: http://davsclaus.com Author of Camel in Action: http://www.manning.com/ibsen
mass async processing - cxf async bot webservice and client
Hallo I need high load - 160 req/s - with large timeout - 20 s - proxy for failover and load balancing, it has to serve async 6400 pending requests. I have following case: I have to expose webservice, which logic is to return result of call of another webservice A-ws, if call to A-ws timeout, I have to return result of call of B-ws, A-ws and B-ws return the same result, but have different location - so I have to build load balancing and failover solution (I will randomly call A and B as first), meanwhile I have to do some logging to database of requests and responses and their statuses. Call to A-ws and B-ws have timeout of 20s (it's hard requirement), system has to service 160 req/s so I can have 20*2 * 160 = 6400 pending requests, so non blocking async is required Now I did some POC with tomcat NIO, async servlets, async cxf webservice server, and async cxf webservice client, solution works quite good, but is not elegant, I wonder if I could do it better and simpler with camel. Do you think it is possible with camel ? does camel support both NIO, and async webservice server and async ws client ? will client and server work async AND withoud pending background thread for each request ? In my solution on tomcat I can serve all pending requests with just one thread will it be possible with camel ? Is it possible to deploy camel on tomcat and expose cxf webservice with cxf servlet ? or I should use jetty provided with camel, and rather camel as standalone app ? Is similar solution possible with camel for https requests and https web page - I expose https www page, that is failover and loadbalancing proxy to 2 other www webpages, both backing web pages have 20s timeout, and load can be 160req/s (similar as above webservice) ? Regards Jakub
Re: ActiveMQ Component: Stop route when no more messages are being received
Thanks Claus, But the exchange.getContext().getInflightRepository.size(routeName) gives me some unpredictable stats. May be I haven't understood it well. The workaround I used is: I wrote a custom stats collector which I wire in the routes of interest. I then just query the variable containing the stats to get count of messages processed so far by the route. Kind Regards, Okello Nelson. On Tue, Jun 4, 2013 at 12:17 PM, Claus Ibsen claus.ib...@gmail.com wrote: You can use the inflight repository to know how many in-flight messages a route has. http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/spi/InflightRepository.html On Mon, Jun 3, 2013 at 4:24 PM, Okello Nelson cn.oke...@gmail.com wrote: Hi Guys, I've been trying to work on this. Time has been hard to come by though. Having thought hard about a potential solution, i think using timer component would be the way to go. When period on the timer elpases, i retrieve the number of exchanges at the endpoints of interest. A timer route like: from(timer://controller?fixedRate=trueperiod=5000).to(ref:routesManager) I retrieve exchanges count in the routesManager bean. Now, my problem is that i still don't know how to retrieve the count of exchanges at an endpoint. Any assistance here will be appreciated very much. BTW: I've also posted this question at stackoverflow.com ( stackoverflow.com/questions/16898646/exchanges-count-at-camel-endpoint). On May 30, 2013 4:48 PM, Okello Nelson cn.oke...@gmail.com wrote: Hi Guys, I'm wondering how to stop an ActiveMQ route and start another one when it's nolonger receiving exchanges. I'm thinking that I probably need to use timeouts, but I'm not sure how to proceed. I've done some research but no success so far. Anyone with a solution, please assist. Kind Regards, Okello Nelson. -- Claus Ibsen - www.camelone.org: The open source integration conference. Red Hat, Inc. FuseSource is now part of Red Hat Email: cib...@redhat.com Web: http://fusesource.com Twitter: davsclaus Blog: http://davsclaus.com Author of Camel in Action: http://www.manning.com/ibsen -- Kind Regards, Okello Nelson +254 722 137 826 cn.oke...@gmail.com
Camel Integration Advice Needed
I have a custom code module which I would like to integrate with an AMQP message bus. In the past I've created (in another language) a messaging broker which managed connections and subscriptions to the AMQP bus. Now creating the code in Java and having discovered Camel I'm trying to write the code in a more flexible manner. I love the XML route configuration of Camel and the power and flexibility it provides - connect to AMQP today, read from a file tomorrow, no code changed. My question is this, my custom code will need to be subscribed to various AMQP routing keys (read topics) which are defined and changing at runtime. The way I see it I can approach this one of three ways: 1) recreate the MQ broker myself to manage the AMQP subscriptions, ditching Camel, and losing out on all the flexibility afforded by Camel 2) Use a route builder to add / subtract routes dynamically to a camel context, leveraging to a certain extent the flexibility of Camel but ultimately still hard coding the AMQP linkage (i.e. drop AMQP, adopt JMS requires a code change) 3) In the Camel XML define an AMQP connector that subscribes to all topics ('#' routing key) on a given exchange and let the receiving custom component do the topic filtering I had really hoped that there was a fourth 'template' type option whereby a route template could be defined in XML that the custom component, using Java, could then instantiate changing topic values in the template where appropriate and adding it into the Camel context as a new route. This would mean that should AMQP be dropped for another integration component the XML would be modified and the custom component would not need to be changed. I am still new to Camel so I'm sure this is likely well trodden ground however my googles are coming back with no satisfactory answer - can anyone provide some guidance? Sincerely, Jason -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Integration-Advice-Needed-tp5734283.html Sent from the Camel - Users mailing list archive at Nabble.com.
camel-hdfs 2.11.0 karaf blueprint
Hi I'm trying to use camel-hdfs with karaf blueprint but I get the error below But I'm not sure if the problem is karaf/osgi/blueprint or my tcp port setting. According to https://svn.apache.org/repos/asf/hadoop/common/branches/branch-0.20/src/hdfs/hdfs-default.xml which is the parameter name/port I have to use for configuring my route to uri=hdfs://poisson.mydomain:9000/tmp/twitter / ? 013-06-17 17:56:27,079 | ERROR | rint Extender: 2 | BlueprintCamelContext | .blueprint.BlueprintCamelContext 130 | 106 - org.apache.camel.camel-blueprint - 2.11.0 | Error occurred during starting Camel: CamelContext(twitter-search-xml2hadoop) due Failed to create Producer for endpoint: Endpoint[hdfs://poisson.mydomain:9000/tmp/]. Reason: java.io.IOException: No FileSystem for scheme: hdfs org.apache.camel.FailedToCreateProducerException: Failed to create Producer for endpoint: Endpoint[hdfs://poisson.mydomain:9000/tmp/twitter]. Reason: java.io.IOException: No FileSystem for scheme: hdfs at org.apache.camel.impl.ProducerCache.doGetProducer(ProducerCache.java:395)[89:org.apache.camel.camel-core:2.11.0] at org.apache.camel.impl.ProducerCache.acquireProducer(ProducerCache.java:114)[89:org.apache.camel.camel-core:2.11.0] at org.apache.camel.impl.ProducerCache.startProducer(ProducerCache.java:145)[89:org.apache.camel.camel-core:2.11.0] at org.apache.camel.processor.SendProcessor.doStart(SendProcessor.java:175)[89:org.apache.camel.camel-core:2.11.0] at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:61)[89:org.apache.camel.camel-core:2.11.0] at org.apache.camel.util.ServiceHelper.startService(ServiceHelper.java:64)[89:org.apache.camel.camel-core:2.11.0] at org.apache.camel.util.ServiceHelper.startService(ServiceHelper.java:54)[89:org.apache.camel.camel-core:2.11.0] at org.apache.camel.util.ServiceHelper.startServices(ServiceHelper.java:75)[89:org.apache.camel.camel-core:2.11.0] at org.apache.camel.processor.DelegateAsyncProcessor.doStart(DelegateAsyncProcessor.java:78)[89:org.apache.camel.camel-core:2.11.0] -- View this message in context: http://camel.465427.n5.nabble.com/camel-hdfs-2-11-0-karaf-blueprint-tp5734284.html Sent from the Camel - Users mailing list archive at Nabble.com.
Camel Context InterceptStrategy
Hello guys, I’d like to apply custom intercept strategy to a given camel context running in an OSGi environment at runtime. I’ve implemented osgi service-reference listener (blueprint) that is notified when the camel context appears. When the listener is invoked the intercept strategy is added to the camel context. Unfortunately, for the InterceptStrategy to be applied it’s necessary for the camel context to be restarted, but in OSGi environment stopping camel context means unregistering corresponding OSGi service and I’m not able to start is again. So, is there any way to apply intercept strategy to the camel context without its restarting? Best Regards, Sergey Zhemzhitsky ___ CONFIDENTIALITY NOTICE: This email and any files attached to it may be confidential. If you are not the intended recipient you are notified that using, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited. If you have received this email in error please notify the sender and delete this email.
Re: two way ssl with a camel cxf proxy use case on Tomcat
these are two different things (the inbound side configuration you already have and the outbound side configuration you asked for) and depending on what you need at each side, you can configure them independently. 2013/6/17 Nico Mommaerts nico.mommae...@gmail.com Ok thanks! Had already read that but wasn't sure if that was needed if ssl is also defined in Tomcat itself (is it harmful to also configure it there?) On Mon, Jun 17, 2013 at 4:35 PM, Aki Yoshida elak...@gmail.com wrote: you configure the ssl setting at your http conduit configuration. and this is explained in this cxf's online documentation: http://cxf.apache.org/docs/client-http-transport-including-ssl-support.html#ClientHTTPTransport%28includingSSLsupport%29-ConfiguringSSLSupport regards, aki 2013/6/17 Nico Mommaerts nico.mommae...@gmail.com Hey, I'm trying to setup a Camel CXF proxy with two way ssl (message gets sent to camel app over http, camel forwards to an external customer over https, 2 way). My Camel app is running on Tomcat (without Jetty running for CXF, I'm using the CXFServlet). I have experience in setting up Tomcat for 2 way ssl with Spring Webservices, but for Camel/CXF I see some literature about http conduits and keystores. So I'm not sure how to set this up for Camel/CXF, is it enough to configure this on Tomcat level, like I do for normal Spring webservices, or do I need to use the http conduit element in my configuration? Thanks in advance, Nicolas Mommaerts
Need original message at the end of the route
I have camel route. In that, I need to have original message which I received/consumed in from tag at the end of same route (Like below) without using/setting to header or property. As that message is too heavy. I don't want to let down the performance. route from .. process 2 process 3 process 4 process 5 /route Do we have any other mechanism to have the same message/object which i received in from tag at the end of route ? JFYI: all processor are executed sequentially so multicast also not worked in this case. /Sarfaraj -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Need original message at the end of the route
Hi, might consider to store it right in the beginning either to a temp file system or into a database which you could consume on a second route, or with a 6th processor. regards, Achim 2013/6/18 sarfaraj sarfarajsay...@gmail.com I have camel route. In that, I need to have original message which I received/consumed in from tag at the end of same route (Like below) without using/setting to header or property. As that message is too heavy. I don't want to let down the performance. route from .. process 2 process 3 process 4 process 5 /route Do we have any other mechanism to have the same message/object which i received in from tag at the end of route ? JFYI: all processor are executed sequentially so multicast also not worked in this case. /Sarfaraj -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290.html Sent from the Camel - Users mailing list archive at Nabble.com. -- Apache Karaf http://karaf.apache.org/ Committer PMC OPS4J Pax Web http://wiki.ops4j.org/display/paxweb/Pax+Web/ Committer Project Lead OPS4J Pax for Vaadin http://team.ops4j.org/wiki/display/PAXVAADIN/Home Commiter Project Lead blog http://notizblog.nierbeck.de/
Re: Activemq consumer is closing
Hello, can you explain what is the actual solution you applied in order to avoid this exception. I am facing the same issue and I really need a help. -- View this message in context: http://camel.465427.n5.nabble.com/Activemq-consumer-is-closing-tp5731140p5734294.html Sent from the Camel - Users mailing list archive at Nabble.com.
Sticky load balancer and failover support
Hi all,I'm trying to implement a sticky balancer using camel framework. Following camel-example-cxf-proxy example I managed to do the following: //*[local-name() = 'incidentId']/text() it's working just fine, routing SOAP requests and sticking them to the right end point basing on incidentId parameter.Now I want to add failover e.g. i would like to avoid requests to be sent to callRealWebService2 if it is down. Do you see any way to do this?Thanks in advance,Davide -- View this message in context: http://camel.465427.n5.nabble.com/Sticky-load-balancer-and-failover-support-tp5734295.html Sent from the Camel - Users mailing list archive at Nabble.com.
Consume opened excel file with ftp
Hello. I'm sorry i'm really a newbie with Camel. I'm using Camel to get file in a FTP server. Here how i'm routing it: The file is a Excel file. When this file is not opened, the download and the process work perfectly. Bug if the FTP server owner save the file in the ftp directory (so it is still open in Excel), when trying to download the file, an exception is thrown: Just closing the file will resolve the problem. Is there a solution to make it waiting to the file to be closed before attempting to consume it? -- View this message in context: http://camel.465427.n5.nabble.com/Consume-opened-excel-file-with-ftp-tp5734296.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Need original message at the end of the route
Saving it on the headers, files or database is probably the easiest way. However, I know that when using exeception handlers you have the option to get the original message: http://camel.apache.org/exception-clause.html#ExceptionClause-UsinguseOriginalMessage So I asume the original message is already stored somewhere, but I don't know where, or if it is possible to access it in a normal route. So you might have to dig into the sourcecode to find it. Or perhaps one of the devs can shed some light on this. -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290p5734297.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Sticky load balancer and failover support
Sorry, the source was not readable. HYG route streamCache=true from uri=cxf:bean:reportIncident?dataFormat=MESSAGE/ to uri=log:input?level=DEBUG/ to uri=bean:enrichBean/ loadBalance sticky correlationExpression xpath resultType=java.lang.String//*[local-name() = 'incidentId']/text()/xpath /correlationExpression /sticky to ref=callRealWebService/ to ref=callRealWebService1/ to ref=callRealWebService2/ /loadBalance to uri=log:output/ /route -- View this message in context: http://camel.465427.n5.nabble.com/Sticky-load-balancer-and-failover-support-tp5734295p5734298.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Need original message at the end of the route
did u try streamcache? http://camel.apache.org/stream-caching.html route streamCache=true -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290p5734299.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Exception when using FTP as endpoint
You may have to provide proper credentials (user password)? Best, Christian Sent from a mobile device Am 18.06.2013 08:02 schrieb Richa rsinha2...@gmail.com: I have two camel routes. The first camel route takes input from JMS and sends to FTP location. Also, the first rotue sends that file to a seda location. This seda location is the input for the second route which again processes the file and sends it to the same FTP location. But when I run this route I get the following exception: *Writing file failed with: File operation failed: 530 Login authentication failed* My two routes look like this: from(fromLocation) .marshal().gzip() .to(toLocation) .to(seda:BillingSedaLocation+routeId); from(seda:BillingSedaLocation+routeId) .unmarshal().gzip() .process(new SomeProcessor()) .to(toLocation); The fromLocation is a jmsQueue and the toLocation is a FTP endpoint. -- View this message in context: http://camel.465427.n5.nabble.com/Exception-when-using-FTP-as-endpoint-tp5734270.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Need original message at the end of the route
I had a quick look at the source code and apparently it is already stored on the exchange, and you can get it from the UnitOfWork. from(direct:/start) .process(new Processor() { @Override public void process(Exchange exchange) throws Exception { Exchange originalMessage = (Exchange) exchange.getUnitOfWork().getOriginalInMessage(); } }); I haven't tested this, but you can give it a try. -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290p5734302.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Need original message at the end of the route
Yes Diether, I thought of Original Message before. But didn't get a way to access that. Could someone know how to get it ? /Sarfaraj -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290p5734301.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Performance Degradation due to Reverse DNS Lookups
We already do something similar: SNIP SSLContext ctx = SSLContext.getInstance(SSL); ctx.init(null, new TrustManager[] { new TrustAllTrustManager() }, null); SSLSocketFactory ssf = new SSLSocketFactory(ctx, SSLSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER); /SNIP This issue does not have to do with the host name verifier or with camel per se, but more to do with the fact that Java core implementation will try to do a reverse dns lookup when creating a secure connection to an ip address. There are workarounds, but those would need to be implemented in camel. Cheers rouble On Mon, Jun 3, 2013 at 10:47 PM, Willem jiang willem.ji...@gmail.com wrote: Hi, I'm not sure if setting the dummy implementation of X509HostnameVerifier can resolve the issue. Can you try it to see if it work? -- 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.com/) (English) http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese) Twitter: willemjiang Weibo: 姜宁willem On Tuesday, June 4, 2013 at 10:23 AM, rouble wrote: In my router configuration I am specifying https4 - is that what you wanted to know? cheers rouble On Mon, Jun 3, 2013 at 9:59 PM, Willem jiang willem.ji...@gmail.com (mailto:willem.ji...@gmail.com) wrote: Hi, There are lots of http related components can provide the https connection, it could be helpful if you can tell us which http component you are using. -- 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.com/) (English) http://jnn.iteye.com (http://jnn.javaeye.com/) (Chinese) Twitter: willemjiang Weibo: 姜宁willem On Tuesday, June 4, 2013 at 5:20 AM, rouble wrote: Camel Dudes, We have detected a very strange issue in that our https routes degrade in performance when an ip address is used (as opposed to a domain name). Turns out that the Java core libraries do reverse DNS lookup for ip address when SSL connections are created. Read all about it here: https://forums.oracle.com/forums/thread.jspa?threadID=1532033 http://stackoverflow.com/questions/3193936/how-to-disable-javas-ssl-reverse-dns-lookup This becomes an issue when the IP address is not configured in the DNS server and the reverse DNS fails. In this case each connection has to wait for a timeout of the reverse DNS request before it can proceed. This makes domain name connections faster than ip address connections - which is backwards. Is this a known issue? There are a few workarounds/hacks recommended on the interwebs, I was wondering if it would be possible to introduce them into camel (http://www.velocityreviews.com/forums/showpost.php?p=2959030postcount=8). tia, rouble
Re: Need original message at the end of the route
This only seems to be done for JmsMessages though. What is the source of your route? -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290p5734303.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Need original message at the end of the route
It is a CXF web service -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290p5734305.html Sent from the Camel - Users mailing list archive at Nabble.com.
Hibernate with restlet
Hi All, I completed the basic hibernate example given in http://camel.apache.org/hibernate-example.html Now I trying hibernate with restlet in apache camel. I want to return a row(s) from database, with a REST GET request. That means a simple select query over database. How to achive this scenario using hibernate component .In example given like this route id=processOrder-route from uri= hibernate:org.apacheextras.camel.examples.hibernate.Order?delay=1s/ to uri=bean:orderBean?method=processOrder/ log message=${body}/ /route But in my case from route is from restlet. One more doubt. Is it possible to Hibernate context inside processor class Thanks in advance -- Jinesh M.K Amrita Vishwa Vidyapeetham mkjin...@gmail.com
Re: Need original message at the end of the route
It works :) exchange.getUnitOfWork().getOriginalInMessage(); Thank you /Sarfaraj -- View this message in context: http://camel.465427.n5.nabble.com/Need-original-message-at-the-end-of-the-route-tp5734290p5734307.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Camel Mustache Handlebars components
Hi Claus, You can do what you want with this source code. I can do a pull request or patch if you wish. The Mustache component works perfectly in our case: it's simple and fast. The Handlebars component/engine is slow at times. Gérald 2013/6/16 Claus Ibsen-2 [via Camel] ml-node+s465427n5734241...@n5.nabble.com Hi Gerald This seems great. I am sure you had fun writing these components. And it even has documentation :) Are you considering donating your components to Apache Camel? http://camel.apache.org/contributing.html We can add a link to your components if you want to keep em at github on this page http://camel.apache.org/user-stories.html On Sat, Jun 8, 2013 at 10:21 PM, gquintana [hidden email]http://user/SendEmail.jtp?type=nodenode=5734241i=0 wrote: Hi all, Just for the fun, I wrote Camel components using Mustache or Handlebars templating engines: https://github.com/gquintana/camel-stuff Cheers, Gérald -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Mustache-Handlebars-components-tp5734043.html Sent from the Camel - Users mailing list archive at Nabble.com. -- Claus Ibsen - www.camelone.org: The open source integration conference. Red Hat, Inc. FuseSource is now part of Red Hat Email: [hidden email]http://user/SendEmail.jtp?type=nodenode=5734241i=1 Web: http://fusesource.com Twitter: davsclaus Blog: http://davsclaus.com Author of Camel in Action: http://www.manning.com/ibsen -- If you reply to this email, your message will be added to the discussion below: http://camel.465427.n5.nabble.com/Camel-Mustache-Handlebars-components-tp5734043p5734241.html To unsubscribe from Camel Mustache Handlebars components, click herehttp://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_codenode=5734043code=Z2VyYWxkLnF1aW50YW5hQGdtYWlsLmNvbXw1NzM0MDQzfDE3MDU3NjA3NjE= . NAMLhttp://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=macro_viewerid=instant_html%21nabble%3Aemail.namlbase=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespacebreadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Mustache-Handlebars-components-tp5734043p5734310.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: MailComponent/MailConsumer misses Mails
Hello, I've updated our customers qa system to camel 2.11.0 and mail 1.5 now. We've added some test routes to send mails to the mail box we are reading from and had a look at it if mails are missing. After ~1 hour we saw that sent mails vs. received mails was not equal anymore and analyzed the log files. I've found the log entries where something is wrong: There are 2 recent mails, but they were not fetched: INFO | jvm 1| 2013/06/18 16:32:21 | * 2 RECENT INFO | jvm 1| 2013/06/18 16:32:21 | * SEARCH INFO | jvm 1| 2013/06/18 16:32:21 | A2749 OK Completed (0 msgs in 0.000 secs) For comparing here are log entries where mails are consumed correctly: 2 Recent and 2 fetched INFO | jvm 1| 2013/06/18 16:32:43 | * 2 RECENT INFO | jvm 1| 2013/06/18 16:32:43 | * SEARCH 1069 1070 INFO | jvm 1| 2013/06/18 16:32:43 | A2777 OK Completed (2 msgs in 0.000 secs) Here is the setup of our routes: Consumerroute: imap://ip-adress?consumer.delay=3000consumer.useFixedDelay=truedebugMode=truefetchSize=1password=_unseen=trueusername= 2 routes which send to the mailbox: timer://foo?fixedRate=trueperiod=27000 timer://foo2?fixedRate=trueperiod=29000 I've activated mailDebug option on the consumer route and additionally some log4j logging: log4j.logger.org.apache.camel.component.mail=TRACE log4j.logger.org.apache.camel.impl=TRACE Pls let me know if I you need other logs or how I should adjust log4j to get more logs out of the MailComponent. kind regards, Christoph -- View this message in context: http://camel.465427.n5.nabble.com/MailComponent-MailConsumer-misses-Mails-tp5733010p5734311.html Sent from the Camel - Users mailing list archive at Nabble.com.
Problem with Camel FTP component because of bug in commons-net
Hi, I just stumbled upon a bug in Apache Commons Net 3.2 / FTPClient. The bug is known and fixed in Commons Net 3.3: https://issues.apache.org/jira/browse/NET-502 The problem was with the FTP producer, when after putting a file to the server, I got a 5xx error as Camel tries to change back to the current working dir (see FtpOperations.storeFile()). This happened due to incorrect parsing of the reply from a PWD in FTPClient.__parsePathname() when getting the current working dir. For a first work-around I excluded the commons-net:3.2 dependency of camel-ftp in my Maven setup and added a dependency to commons-net:3.3. Since this is quite a fundamental bug, it would be great if Camel-FTP would be upgraded to use the current version of commons-net with the next Camel release. Regards Carsten
Servet Componnet HttpSession
I've setup a proxy using Tomcat Servlet component but when end point service receives Http request the HttpSessionId is the same for all clients when the proxy is involved. Is there a special setting that needs to be enabled for Servlet component? I noticed only Jetty component has sessionSupport unfortunately i cannot use Jetty. /Ramon -- View this message in context: http://camel.465427.n5.nabble.com/Servet-Componnet-HttpSession-tp5734314.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Hibernate with restlet
I'm afraid, this use case isn't supported yet. If you use the hibernate-component in a to(), it will do an insert/update. This is the same for the JPA component. You should consider to use the sql or jdbc component. Best, Christian Müller - Software Integration Specialist Apache Camel committer: https://camel.apache.org/team V.P. Apache Camel: https://www.apache.org/foundation/ Apache Member: https://www.apache.org/foundation/members.html https://www.linkedin.com/pub/christian-mueller/11/551/642 On Tue, Jun 18, 2013 at 4:59 PM, Jinesh M.K mkjin...@gmail.com wrote: Hi All, I completed the basic hibernate example given in http://camel.apache.org/hibernate-example.html Now I trying hibernate with restlet in apache camel. I want to return a row(s) from database, with a REST GET request. That means a simple select query over database. How to achive this scenario using hibernate component .In example given like this route id=processOrder-route from uri= hibernate:org.apacheextras.camel.examples.hibernate.Order?delay=1s/ to uri=bean:orderBean?method=processOrder/ log message=${body}/ /route But in my case from route is from restlet. One more doubt. Is it possible to Hibernate context inside processor class Thanks in advance -- Jinesh M.K Amrita Vishwa Vidyapeetham mkjin...@gmail.com
Re: Camel Mustache Handlebars components
If you want to contribute the component(s) to Apache Camel (we love contributions), you should: 1) open a JIRA at https://issues.apache.org/jira/browse/CAMEL 2) Attach the component as patch file or create a pull request (please mention the JIRA ticket number) 3) Attach the the documentation for the component to the JIRA (have a look how similar WIKI pages look: https://cwiki.apache.org/confluence/display/CAMEL/Velocity) 4) Done :-) Otherwise, we can add a link to your component from our user stories page. Best, Christian Müller - Software Integration Specialist Apache Camel committer: https://camel.apache.org/team V.P. Apache Camel: https://www.apache.org/foundation/ Apache Member: https://www.apache.org/foundation/members.html https://www.linkedin.com/pub/christian-mueller/11/551/642 On Tue, Jun 18, 2013 at 5:25 PM, gquintana gerald.quint...@gmail.comwrote: Hi Claus, You can do what you want with this source code. I can do a pull request or patch if you wish. The Mustache component works perfectly in our case: it's simple and fast. The Handlebars component/engine is slow at times. Gérald 2013/6/16 Claus Ibsen-2 [via Camel] ml-node+s465427n5734241...@n5.nabble.com Hi Gerald This seems great. I am sure you had fun writing these components. And it even has documentation :) Are you considering donating your components to Apache Camel? http://camel.apache.org/contributing.html We can add a link to your components if you want to keep em at github on this page http://camel.apache.org/user-stories.html On Sat, Jun 8, 2013 at 10:21 PM, gquintana [hidden email] http://user/SendEmail.jtp?type=nodenode=5734241i=0 wrote: Hi all, Just for the fun, I wrote Camel components using Mustache or Handlebars templating engines: https://github.com/gquintana/camel-stuff Cheers, Gérald -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Mustache-Handlebars-components-tp5734043.html Sent from the Camel - Users mailing list archive at Nabble.com. -- Claus Ibsen - www.camelone.org: The open source integration conference. Red Hat, Inc. FuseSource is now part of Red Hat Email: [hidden email] http://user/SendEmail.jtp?type=nodenode=5734241i=1 Web: http://fusesource.com Twitter: davsclaus Blog: http://davsclaus.com Author of Camel in Action: http://www.manning.com/ibsen -- If you reply to this email, your message will be added to the discussion below: http://camel.465427.n5.nabble.com/Camel-Mustache-Handlebars-components-tp5734043p5734241.html To unsubscribe from Camel Mustache Handlebars components, click here http://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_codenode=5734043code=Z2VyYWxkLnF1aW50YW5hQGdtYWlsLmNvbXw1NzM0MDQzfDE3MDU3NjA3NjE= . NAML http://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=macro_viewerid=instant_html%21nabble%3Aemail.namlbase=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespacebreadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Mustache-Handlebars-components-tp5734043p5734310.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: camel deployment options...
Hi Ben! I hope you are doing good. We missed you at CamelOne in Boston... I would recommend Tomcat, if: - you don't have to support updating individual bundles at run time without to have a downtime of the entire application (of course it doesn't work if you provide a JAX-WS, JAX-RS, ... interface in this bundle) - you don't have to deploy multiple services into a single Tomcat (bigger deployments) - you don't use cellar/fabric (I'm not sure, but I don't think they work in Tomcat - we don't use it) Otherwise (as we do it), use Karaf or ServiceMix. My 0,02 €, Christian Müller - Software Integration Specialist Apache Camel committer: https://camel.apache.org/team V.P. Apache Camel: https://www.apache.org/foundation/ Apache Member: https://www.apache.org/foundation/members.html https://www.linkedin.com/pub/christian-mueller/11/551/642 On Mon, Jun 17, 2013 at 7:18 PM, boday ben.o...@initekconsulting.comwrote: I have a complex/high volume (1k msgs/s) Camel application running in ActiveMQ that I need to scale up (2-5x traffic). To date, we scaled by adding more AMQ/Camel VMs and partitioned traffic to each broker. My thought is that decoupling Camel from AMQ and adding nodes independently is a better way to scale horizontally and adds flexibility/reliability to the architecture... Assuming this, the question becomes what container to use for the Camel apps. I've used both Karaf and Tomcat in the past, but am curious what others are doing these days in this regard. Karaf is undoubtedly the better choice in terms of flexibility, but I tend to fallback to Tomcat because its a simpler migration path/learning curve for my client (which is a factor). Any thoughts on this architecture/deployment model? - Ben O'Day IT Consultant -http://consulting-notes.com -- View this message in context: http://camel.465427.n5.nabble.com/camel-deployment-options-tp5734266.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Consume opened excel file with ftp
You can use the bridgeErrorHandler to discard this exception. Camel will try to consume this file again in the next poll. But this is more a work around... You should consider to write the file into a different directory and move it into the directory Camel is polling afterwards. Best, Christian Sent from a mobile device Am 18.06.2013 14:31 schrieb axelf cale...@orange.fr: Hello. I'm sorry i'm really a newbie with Camel. I'm using Camel to get file in a FTP server. Here how i'm routing it: The file is a Excel file. When this file is not opened, the download and the process work perfectly. Bug if the FTP server owner save the file in the ftp directory (so it is still open in Excel), when trying to download the file, an exception is thrown: Just closing the file will resolve the problem. Is there a solution to make it waiting to the file to be closed before attempting to consume it? -- View this message in context: http://camel.465427.n5.nabble.com/Consume-opened-excel-file-with-ftp-tp5734296.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Servet Componnet HttpSession
It looks like Camel caches the client connection as long as URL is exactly the same. This causes multiple requests by different browser clients to use same session id. Is this expected behavior? It does not seem correct to me for two different clients to have the same session id on server simply because they use the same URL. Use case is that Camel is acting as a proxy with a slip configuration that routes the request to a servlet component. /Ramon -- View this message in context: http://camel.465427.n5.nabble.com/Servet-Componnet-HttpSession-tp5734314p5734320.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Activemq consumer is closing
There is not enough input that we can start digging into it... http://camel.apache.org/support.html Best, Christian Sent from a mobile device Am 18.06.2013 14:01 schrieb indrayani ind.k...@gmail.com: Hello, can you explain what is the actual solution you applied in order to avoid this exception. I am facing the same issue and I really need a help. -- View this message in context: http://camel.465427.n5.nabble.com/Activemq-consumer-is-closing-tp5731140p5734294.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: Camel Context InterceptStrategy
I guess you already studied http://camel.apache.org/intercept.html Best, Christian Sent from a mobile device Am 18.06.2013 12:45 schrieb Zhemzhitsky Sergey sergey_zhemzhit...@sberbank-cib.ru: Hello guys, I’d like to apply custom intercept strategy to a given camel context running in an OSGi environment at runtime. I’ve implemented osgi service-reference listener (blueprint) that is notified when the camel context appears. When the listener is invoked the intercept strategy is added to the camel context. Unfortunately, for the InterceptStrategy to be applied it’s necessary for the camel context to be restarted, but in OSGi environment stopping camel context means unregistering corresponding OSGi service and I’m not able to start is again. So, is there any way to apply intercept strategy to the camel context without its restarting? Best Regards, Sergey Zhemzhitsky ___ CONFIDENTIALITY NOTICE: This email and any files attached to it may be confidential. If you are not the intended recipient you are notified that using, copying, distributing or taking any action in reliance on the contents of this information is strictly prohibited. If you have received this email in error please notify the sender and delete this email.
Re: Hibernate with restlet
Thanks Muller. I started with sql component. On 19 June 2013 02:03, Christian Müller christian.muel...@gmail.com wrote: I'm afraid, this use case isn't supported yet. If you use the hibernate-component in a to(), it will do an insert/update. This is the same for the JPA component. You should consider to use the sql or jdbc component. Best, Christian Müller - Software Integration Specialist Apache Camel committer: https://camel.apache.org/team V.P. Apache Camel: https://www.apache.org/foundation/ Apache Member: https://www.apache.org/foundation/members.html https://www.linkedin.com/pub/christian-mueller/11/551/642 On Tue, Jun 18, 2013 at 4:59 PM, Jinesh M.K mkjin...@gmail.com wrote: Hi All, I completed the basic hibernate example given in http://camel.apache.org/hibernate-example.html Now I trying hibernate with restlet in apache camel. I want to return a row(s) from database, with a REST GET request. That means a simple select query over database. How to achive this scenario using hibernate component .In example given like this route id=processOrder-route from uri= hibernate:org.apacheextras.camel.examples.hibernate.Order?delay=1s/ to uri=bean:orderBean?method=processOrder/ log message=${body}/ /route But in my case from route is from restlet. One more doubt. Is it possible to Hibernate context inside processor class Thanks in advance -- Jinesh M.K Amrita Vishwa Vidyapeetham mkjin...@gmail.com -- Jinesh M.K Technical Lead Amrita Center for Cyber Security | Amrita Vishwa Vidyapeetham (+91) 9400466629 | 0476 2804530 http://jinutechworld.blogspot.com | mkjin...@gmail.com
Camel routes and threads
Hello, As I learnt, each route in camel runs in its own thread unless its a direct endpoint. We have a configuration, where we have 14 different routes inside the camel context: We are seeking clarification on following points: 1. the defaultThreadPolicy has poolSize=10 maxPoolSize=20. Does that mean that maximum of 10 threads will be executing the 10 routes at a time out of the 14 configured. If yes, can we override this configuration using threadPoolProfile such that poolSize=5 maxPoolSize=5 do that there are only 5 threads which execute 5 different routes at a given point in time ? 2. Is there any way by which we can limit the number of thread spawned to executes routes ? We are seeking the above information, because we are encountering out of memory exception. The reason for this, as we see is, there is a customized Publish-Subscribe mechanism and we have converted that to a customized endpoint. This endpoint is used in 14 different routes and we get messages on all of these endpoints which are processed. Since everything is in the same camel context, we run out of memory during this parallel processing. This is where we need to limit number of threads which process the routes in parallel. Appreciate any help. Thank you, Regards vkarkhanis -- View this message in context: http://camel.465427.n5.nabble.com/Camel-routes-and-threads-tp5734326.html Sent from the Camel - Users mailing list archive at Nabble.com.
Camel JMS retry mechanism
Hi, I have a camel route having JMS as input location. I want to handle the scenario when JMS is down. I would like to restrict the number of retries to 2 in case JMS is down. But when I looked through the messageListenerContainer class I realized that the method which is called to connect to the JMS is called in a thread. Maybe I am intrepreting it wrong, but it always keeps on retrying for infinite number of times. Also no exception is explicitly thrown so I cannot have an onException block. Please tell me how can I restrict the number of retries. -- View this message in context: http://camel.465427.n5.nabble.com/Camel-JMS-retry-mechanism-tp5734328.html Sent from the Camel - Users mailing list archive at Nabble.com.