TypeConverterLoaderException in webstart

2011-05-26 Thread Jim Newsham
We've come across a problem in Camel 2.7.1 where Camel fails to start up due to a TypeConverterLoaderException. This is a regression, as we've had no such problem in Camel 2.5.0. Is this a known issue? Googling around, I've found [1], which states: My second problem is that it's current

Re: set jms reply to in message header

2011-05-26 Thread Jim Newsham
Hi Willem, We do not want to use a temporary queue for replies, because it is scoped to the lifetime of the connection, and any data sent to that queue will be lost if the connection gets lost for some reason. We can't set the replyTo queue at route definition time because the reply queue n

Re: set jms reply to in message header

2011-05-26 Thread Willem Jiang
Hi Jim, Claus give some inputs on the CAMEL-4008, one of his concern is letting the user setting the ReplyTo property will cause some memory leak, as camel-jms will start a jms listener per reply queue and only release it when the camel context is shut down, I don't know why you want to set

Re: Can Camel communicate over IBM MQ sender/receiver channels?

2011-05-26 Thread peterjca
Hi Ashwin, Thanks for the response. However, I don't think this is what I need as this appears to simply be a queue to queue communication which I can already do with ActiveMQ. My situation has a connection factory that looks like:

Re: Can Camel communicate over IBM MQ sender/receiver channels?

2011-05-26 Thread Ashwin Karpe
Hi, Please check out the code below Enjoy, Ashwin... -- http://www.springframework.org/schema/beans"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation=" http://www.springframewor

Re: email listener

2011-05-26 Thread Jim Talbut
Some time ago someone wrote here about an actual SMTP listener component for Camel, I think it was part of Apache James. The project that made me interested in it got canned, so I don't know whether it ever vecame usable. Jim On 26/05/2011 21:57, Donald Whytock wrote: from("pop3://m...@emailh

Re: email listener

2011-05-26 Thread Donald Whytock
from("pop3://m...@emailhost.com?password=password") choice().when(header("subject").contains("keyword")) to("jms://queuespec"); That's roughly the java. I think it can also be done in XML with no java at all. Don On Thu, May 26, 2011 at 4:11 PM, fachhoch wrote: > I want  an email listene

Producer or ProducerTemplate

2011-05-26 Thread Samuel Cox
Hi, I've created a black-box request/response facade around a Camel route. Think: class BlackBox { function process(request: Request): Response } This thing lives in a spring environment and is getting the CamelContext injected. For each blackBox call, I use the context to: 1. Lookup an end

email listener

2011-05-26 Thread fachhoch
I want an email listener , ie whenever a new email arrives to a particular inbox with a particular subject I want a jms message to be sent to my listener , can camel do this ? -- View this message in context: http://camel.465427.n5.nabble.com/email-listener-tp4429925p4429925.html Sent

Re: aggregator - error handling default does not propogate error

2011-05-26 Thread Mond Raymond
Again, just a follow up note, I simplified this in the end as in: public class GetVehicleData extends RouteBuilder { private String fromURI; @Override public void configure() throws Exception { from(fromURI).multicast(new VehicleDataAggregator()).stopOnException()

Re: FTP to HDFS - large gzipped files

2011-05-26 Thread Mond Raymond
Claus, Just thought I would follow up. I don't know if this counts as a contribution, but I ended up doing this as a splitter as in: from(fromUri) .split().method(OuterZipFileDecompressingSplitter.class, "split") .streaming() .parallelPro

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
Thank you Willem! I changed the TCCL before creating the camel context and restored it after the route was started - that did the trick. Now, I wonder, is this really a good design? A properly designed OSGI enabled component shouldn't use the TCCL right? Isn't that one of the big problems when us

Re: CXFRS and XML validation

2011-05-26 Thread Bruno Dusausoy
On 26/05/2011 17:15, Bruno Dusausoy wrote: [...] Hi Claus, I've tried but I realized very soon that it is useless since the route start with the cxfrs endpoint and immediately take the payload and tries to unmarshall it, *before* hitting the validation component, making the latter useless. May

Re: loadRoutesDefinition and jaxb.index

2011-05-26 Thread Charles Moulliard
Have you tried to create the process like that from(queue) .process(new Processor() { public void process(Exchange e) throws Exception { String xml = (String) e.getIn().getBody(); InputStream

Re: an un-easy way to use camel-xpath in:header() function

2011-05-26 Thread Claus Ibsen
On Mon, May 23, 2011 at 5:39 AM, ext2 wrote: > Hi, Claus: > Yes you are right. > The use case(header xml) isn't so widespread as the  use-case( body xml) > > When we find the body is not xml(it's very easy to check), how about to give > the user another chance to deal with header using in:header f

Re: loadRoutesDefinition and jaxb.index

2011-05-26 Thread virgile.dev...@atosorigin.com
Charles Moulliard wrote: > > How have created your camelContext ? > The first route reads form a activemq queue. It receives the xml file and create a processor giving him the message and its camelcontext. So i do not need to create another camelcontext: DynamicRouteHandler dynamicRouteHandler

Re: @XPath for an Integer

2011-05-26 Thread Claus Ibsen
On Thu, May 26, 2011 at 5:44 PM, boday wrote: > agreed...I'll update the patch.  While we are at it, are there any other > cases that should be addressed? > I wonder if BigDecimal has any similar NaN stuff? > > bvahdat wrote: >> >> I think that not only Double.NaN should be catched but also Flo

Can Camel communicate over IBM MQ sender/receiver channels?

2011-05-26 Thread peterjca
I'm currently investigating the integration of a local ActiveMQ with a remote WebSphere MQ, with message sending and receiving to queues over (the IBM concept of) sender and receiver channels. I've not found anything definitive saying that it's possible and have yet to get a response to my posting

Re: loadRoutesDefinition and jaxb.index

2011-05-26 Thread Charles Moulliard
How have created your camelContext ? On Thu, May 26, 2011 at 5:10 PM, virgile.dev...@atosorigin.com wrote: > Hi Charles, > > the xml file that contains the route is dynamically created by an external > webapp. I receive this file on a jms queue through an already started route. > then this route

Re: @XPath for an Integer

2011-05-26 Thread boday
agreed...I'll update the patch. While we are at it, are there any other cases that should be addressed? bvahdat wrote: > > I think that not only Double.NaN should be catched but also Float.NaN. > - Ben O'Day IT Consultant -http://benoday.blogspot.com -- View this message in context: ht

Re: @XPath for an Integer

2011-05-26 Thread Claus Ibsen
Hi Yeah we should cover all the NaN for the numeric types, both the integers and the floating types. I am sure Ben can add that last pieces for the floating types. On Thu, May 26, 2011 at 1:31 PM, bvahdat wrote: > Hi, > > I think that not only Double.NaN should be catched but also Float.NaN. >

Re: CXFRS and XML validation

2011-05-26 Thread Bruno Dusausoy
On 26/05/2011 17:10, Claus Straube wrote: Hi, you can validate your xml payload with the validation component: http://camel.apache.org/validation.html Hi Claus, I've tried but I realized very soon that it is useless since the route start with the cxfrs endpoint and immediately take the paylo

Re: loadRoutesDefinition and jaxb.index

2011-05-26 Thread virgile.dev...@atosorigin.com
Hi Charles, the xml file that contains the route is dynamically created by an external webapp. I receive this file on a jms queue through an already started route. then this route gives the message to a processor that will load the route from the xml file. Charles Moulliard wrote: > > Hi Virg

Re: CXFRS and XML validation

2011-05-26 Thread Claus Straube
Hi, you can validate your xml payload with the validation component: http://camel.apache.org/validation.html Best regards - Claus On 26.05.2011 17:03, Bruno Dusausoy wrote: Hi, I know this is a common question, but I couldn't find a simple answer for this. Basically what I want to do is to

CXFRS and XML validation

2011-05-26 Thread Bruno Dusausoy
Hi, I know this is a common question, but I couldn't find a simple answer for this. Basically what I want to do is to validate the input of my RESTful web service. What I have is this camel context : http://camel.apache.org/schema/spring";> uri="cxfrs:///?resourceClas

Re: loadRoutesDefinition and jaxb.index

2011-05-26 Thread Charles Moulliard
Hi Virgile, Why do you load the routes like and not using by example as you have a Spring XML File ? http://camel.apache.org/schema/spring";> org.apache.camel.spring.config.scan **/*Excluded* **/* or using a Regards, Charles Moulliard

loadRoutesDefinition and jaxb.index

2011-05-26 Thread virgile.dev...@atosorigin.com
Hello, I try to load a route dynamically from an xml file with camelContext.loadRoutesDefinition. Works fine from my unit test but when i tried to run my bundle in servicemix, i've got an error: Caused by: javax.xml.bind.JAXBException: "org.apache.camel.model.config" doesnt contain ObjectFactory.cl

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Willem Jiang
camel-cxf endpoint will try to use the TCCL to load the class which you specify from the URI with serviceClass option. If you are using spring extender to load camel route, spring will set the TCCL with the bundle class loader and it has no trouble to load the SEI. As you are using iPOJO to injec

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
Willem, Can you explain that a bit? Should I change the thread context classloader prior to creating the camel context? I don't quite understand. /Bengt 2011/5/26 Willem Jiang > Maybe you need to set the thread context classloader with the classloader > which loads the SEI class. > > > On 5/26

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Willem Jiang
Maybe you need to set the thread context classloader with the classloader which loads the SEI class. On 5/26/11 8:50 PM, Bengt Rodehav wrote: Willem, I don't "load" my camel context, I create it programmatically like this: *CamelContextFactory factory = new CamelContextFactory(); fa

AW: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Christian Schneider
Hi Bengt, I think you should create the cxf endpoint using the JaxWsServerFactoryBean like described below: http://cxf.apache.org/docs/jax-ws-java-first-with-jms-transport.html So you just use another address than in the example there. Christian -Ursprüngliche Nachricht- Von: bengt.ro

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
Willem, I don't "load" my camel context, I create it programmatically like this: *CamelContextFactory factory = new CamelContextFactory(); > factory.setBundleContext(bc); > CamelContext context = factory.createContext();* I get the bundle context (bc) from iPOJO when my component is

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
Thanks for you reply Christian, Yes, I did find your article but I guess I didn't understand it correctly... When you say I should create a "normal cxf endpoint" I thought I was supposed to create a route starting with "from("cxf:")" but maybe you mean I should actually do a "new CxfEndpoint()"?

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Willem Jiang
Hi, I'm not sure how do you load the camel context. camel-cxf bundle don't need to import your customer SEI package, you just need to make sure you thread context classloader can load the SEI class. On 5/26/11 7:19 PM, Bengt Rodehav wrote: Hello again Willem, Yes the ITrsWebService class is

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Christian Schneider
I think you can do the CamelTransportfactory setup a little simpler and the route is wrong. A long time ago I wrote an article about the Camel transport for cxf but it should mostly still be valid: https://cwiki.apache.org/confluence/display/CAMEL/Better+JMS+Transport+for+CXF+Webservice+using+

Re: Camel Web Console Questions

2011-05-26 Thread James Strachan
On 26 May 2011 12:57, Jim Talbut wrote: > On 26/05/2011 11:51, James Strachan wrote: >> >> Also we don't need to rewrite camel-web just to provide support for >> multiple contexts; all thats really required is one or two resource >> beans using the OSGi or JMX API to discover the contexts and a >>

Re: Camel Web Console Questions

2011-05-26 Thread Jim Talbut
On 26/05/2011 11:51, James Strachan wrote: Also we don't need to rewrite camel-web just to provide support for multiple contexts; all thats really required is one or two resource beans using the OSGi or JMX API to discover the contexts and a template page or two and multiple contexts could be sup

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
Christian, I tried using the camel transport but I got the same exception (couldn't find the ITrsWebService class). I'm not sure I did it the way you intended. What I did was this: */* ** * Initialize camel transport for CXF ** */ **BusFactory bf = BusFactory.newI

Re: @XPath for an Integer

2011-05-26 Thread bvahdat
Hi, I think that not only Double.NaN should be catched but also Float.NaN. If you add the following lines in ObjectConverterTest the test will fail: assertEquals(null, ObjectConverter.toFloat(Float.NaN)); assertEquals(null, ObjectConverter.toLong(Float.NaN)); So that I think tha

Re: FTP2 Component fails to process multiple files at once

2011-05-26 Thread Laurentiu Trica
Hi Claus, I tried what you said with the synchronous=true option but it doesn't seem to work either. I put that option to all the nmr routes in the test project but it's the same result. Is there anything I missed? This is what I modified: camel-context.xml from the endpoint http://camel.apache.o

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
This sounds like a new angle. Do you have any pointers as to how I do this? Does it limit what I can do with CXF or is it "fully featured"? /Bengt 2011/5/26 Christian Schneider > You might want to try the camel transport for cxf instead. > I think in this case you do not need spring. > > Christ

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
Hello again Willem, Yes the ITrsWebService class is actually part of the bundle that contains the route and its package is exported. When I use Spring with "cxf:bean", as I described earlier, Spring seems to have no problem finding this interface. However, I cannot see that the camel-cxf bundle i

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
Thanks for your answer Willem, however I'm not exactly sure what you mean... Do you mean that if I use "cxf:bean" then the enpoint (and camel context) must be created by Spring? Can I not use "cxf:bean" without using Spring? I want to create the endpoint bean using normal java code - is that poss

AW: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Christian Schneider
You might want to try the camel transport for cxf instead. I think in this case you do not need spring. Christian -Ursprüngliche Nachricht- Von: bengt.rode...@gmail.com [mailto:bengt.rode...@gmail.com] Im Auftrag von Bengt Rodehav Gesendet: Donnerstag, 26. Mai 2011 12:17 An: users@camel

Re: Camel Web Console Questions

2011-05-26 Thread Tarun Ramakrishna
Hi Jim, I also am just another plain Camel user. OSGi and multiple contexts: This is obviously a prime motivation. We need to view and observe the details of multiple Camel Contexts contributed by multiple bundles. The spring extender binds ApplicationContext objects as OSGi services - we want to

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Willem Jiang
On 5/26/11 6:16 PM, Bengt Rodehav wrote: * ITrsWebService serverBean = new TrsWebServiceImpl(); > from("cxf: > http://localhost:9001/trsws/?serviceClass=se.digia.trs.route.webservice.ITrsWebService > ").bean(serverBean);* But for some reason camel-cxf can't seem to find the ITrsWebServ

Re: camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Willem Jiang
Hi, cxf:bean: will use the spring to configure the cxf endpoint. You may use URI to specify the cxf endpoint, but you can't configure the interceptors or features which are usually configured by spring. On 5/26/11 6:16 PM, Bengt Rodehav wrote: * ITrsWebService serverBean = new TrsWebServiceI

Re: Camel Web Console Questions

2011-05-26 Thread James Strachan
I agree with everything Jim just said :) So I'm sure we can trim the size down. e.g. we don't really need the scala compiler for deployment; we can compile all the templates at build time (though its very handy using it at development time for rapid reloading of templates as you edit them on the f

camel-cxf in OSGi, java DSL and iPOJO (no Spring)

2011-05-26 Thread Bengt Rodehav
I have great problems getting camel-cxf to work. I use Camel 2.7.1 running in Karaf 2.2.0. First, lets see what I can get to work... If I create my camel context and my cxf endpoint from within Spring I do get things to work, like this: *META-INF/spring/beans.xml* ... *http://localhost:9000

Re: Camel Web Console Questions

2011-05-26 Thread Jim Talbut
Tarun, I'm just another user, but I've recently been trying to turn camel-web into something that suits my needs. There are certainly problems with camel-web, but I'm not convinced that Tarun's heading in completely the right direction. The two big problems with camel-web for me are: 1. I u

Re: Non-trivial integration using a FTP server

2011-05-26 Thread Javier Arias Losada
Hello, a simple solution may be to use the .session file as a trigger for your routes. The ftp component waits for the .process and then launches your route with a custom processor on the files. Depending on your needs you may treat the files as one unit inside different processors or split them li

RE: Camel CXF RS Consumer. Why serviceClass is required?

2011-05-26 Thread Zhemzhitsky Sergey
Is it possible to instantiate a jdk proxy based on the interface of the service? If so, the code would be cleaner because there will no dummy service implementations? Best Regards, Sergey Zhemzhitsky -Original Message- From: Willem Jiang [mailto:willem.ji...@gmail.com] Sent: Thursday

Re: Camel CXF RS Consumer. Why serviceClass is required?

2011-05-26 Thread Willem Jiang
As the CXF RS need to instantiate the resource class to navigate the resource. That is why we need the serviceClass to be class instead of interface. On 5/26/11 3:37 PM, Zhemzhitsky Sergey wrote: Hi Willem, Ben Thanks for the information. I tried to use the interface instead of class in the s

RE: Camel CXF RS Consumer. Why serviceClass is required?

2011-05-26 Thread Zhemzhitsky Sergey
Hi Willem, Ben Thanks for the information. I tried to use the interface instead of class in the serviceClass attribute and I didn't succeed because of an exception that told that the class is required. Here is the exception: Caused by: java.lang.RuntimeException: Resource class interface org.te