Re: Camel Spring Remoting throwing RuntimeException question

2009-08-05 Thread Claus Ibsen
Hi Thanks for reporting. I did try to reproduce it here but it worked nicely. I added unit tests to Camel itself. You can check the commit here http://svn.apache.org/viewvc?view=rev&revision=801511 Also about the file thingy it worked fine here as well as the .camelLock files are removed after

Re: using xpath tokenize function inside camel

2009-08-05 Thread Claus Ibsen
On Wed, Aug 5, 2009 at 3:58 PM, zoorg wrote: > > No I do not manage to make it working. > I am not sure but my conclusion was that camel use the jdk default > implementation to evaluate XPath expressions which only support XPath > version 1.0. And the "tokenize" function needs XPAth version 2.0. >

Re: Camel 2.0-M3 swalllowing exceptions?

2009-08-05 Thread Claus Ibsen
On Wed, Aug 5, 2009 at 9:01 PM, J_Racker wrote: > > Thanks so much, > > This is my own code.  The reason I'm dealing with camel at this level is > because I'm writing my own Component/Endpoint/Consumer combo for connecting > to a NimBUS Queue.  This code is from the callback method which acts sort

Re: Virtual Topic routing with Camel

2009-08-05 Thread Willem Jiang
Your RouteBuilder into the test method doesn't be added into the camel context. Here is an example of setting the RouteBuilder public class MyTest extends CamelTestSupport { @Test public void yourTest() throws Exception { // do some test here, you can remove the consumer templat

Re: Virtual Topic routing with Camel

2009-08-05 Thread Mick Knutson
So I have this in my unit test now: @EndpointInject(uri = "mock:player1") protected MockEndpoint mockPlayer; @Test public void testGetStatusUpdateMessage() throws Exception { log.info("testGetStatusUpdateMessage"); // we expect Hello World received in our mock end

Re: Virtual Topic routing with Camel

2009-08-05 Thread Willem Jiang
I think the consumer template should work. String body = consumer.receiveBody("activemq:Player.1.VirtualTopic.TABLE.1", String.class); Or you can try to setup the route rule first for the Unit test. form("activemq:Player.1.VirtualTopic.TABLE.1").to("mock:player1"); then you can using the camel

Re: Camel Smart Proxy Integration Pattern

2009-08-05 Thread Willem Jiang
Hi, camel-jms support the Request/Reply[1] EIP out of box. In you case, you could let use the polling thread to send the request to the message queue and wait for the response. If you want to correlate the request message and response message yourself in different thread, you need to set up

Re: Virtual Topic routing with Camel

2009-08-05 Thread Mick Knutson
That is what I am trying to wrap my head around. I am trying to figure out a way to either create a consumer like: http://camel.apache.org/activemq.html But still can't seem to understand how to fit this into a unit test in question. Not sure how that sets a remote destination which is what I need

Re: Virtual Topic routing with Camel

2009-08-05 Thread Willem Jiang
Can your consumer start to receive the message before calling the sendStatusUpdate method ? You may need using other thread to call the sendStatusUpdate. Willem Mick Knutson wrote: Is there anything else I would have to setup with my embedded broker to be able to test sending a message to a V

Re: Camel OSGI is not working in Eclipse RCP 3.5

2009-08-05 Thread Willem Jiang
We did some enhancement[1] on this issue two month ago. If you don't want to Camel 2.0M3 or Camel 1.6.2-SNAPSHOT, here is way to walk around this issue. Please try to import the org/apache/activemq/camel/converter package in your camel context bundle. Willem [1] https://issues.apache.org/acti

Virtual Topic routing with Camel

2009-08-05 Thread Mick Knutson
Is there anything else I would have to setup with my embedded broker to be able to test sending a message to a VirtualTopic to get routed to the subscribed Queues? Here is what I have on my server: *...@endpointinject(uri="activemq:**VirtualTopic.TABLE.1") ProducerTemplate producer;

Camel OSGI is not working in Eclipse RCP 3.5

2009-08-05 Thread otech
Hi all, I am facing a problem when using Camel in Eclipse RCP. In our project, we using spring and camel in Eclipse RCP for processing JMS message. The problem happening for the converter loading into camel context. I looked at some post in Camel Bugzilla. It said it had been fixed in 1.6. But it

Re: Camel 2.0-M3 swalllowing exceptions?

2009-08-05 Thread J_Racker
Thanks so much, This is my own code. The reason I'm dealing with camel at this level is because I'm writing my own Component/Endpoint/Consumer combo for connecting to a NimBUS Queue. This code is from the callback method which acts sort of like a message listener. John Claus Ibsen-2 wrote: >

Re: Camel 2.0-M3 swalllowing exceptions?

2009-08-05 Thread Claus Ibsen
Hi On Wed, Aug 5, 2009 at 8:44 PM, J_Racker wrote: > > I'm having a problem when setting up a route in camel.  In the process of > debugging a new camel route I noticed that I could not connect to my > Activemq Broker because of authentication.  So during the route when the > message is sent to th

Camel 2.0-M3 swalllowing exceptions?

2009-08-05 Thread J_Racker
I'm having a problem when setting up a route in camel. In the process of debugging a new camel route I noticed that I could not connect to my Activemq Broker because of authentication. So during the route when the message is sent to the queue, the following exception is thrown (javax.jms.JMSExce

Re: Error when using XPath functions

2009-08-05 Thread Dragisa Krsmanovic
Claus Ibsen-2 wrote: > > On Wed, Aug 5, 2009 at 12:59 AM, Dragisa Krsmanovic > wrote: >> >> Camel 2.0-M3, trying setHeader like: >> >> >>   substring(//atom:entry/atom:id/text(), 9) >> >> >> //atom:entry/atom:id/text() returns correct result, but if I try to use >> any >> of the XPath function

Re: using xpath tokenize function inside camel

2009-08-05 Thread zoorg
No I do not manage to make it working. I am not sure but my conclusion was that camel use the jdk default implementation to evaluate XPath expressions which only support XPath version 1.0. And the "tokenize" function needs XPAth version 2.0. But I think my problem is different than the other user

Re: bean binding with inheritance & 2.0-M3 camel-http

2009-08-05 Thread Claus Ibsen
Hi Also the bean method name issue has been fixed in trunk. So if possible please test it at your side by building from source or try SNAPSHOT when a new build is published to apache maven repos. On Wed, Aug 5, 2009 at 1:55 PM, Claus Ibsen wrote: > Hi > > Okay I am committing a fix in short time.

Re: bean binding with inheritance & 2.0-M3 camel-http

2009-08-05 Thread Mick Knutson
JJ or Clause, can you help understand this use case? Are you trying to have a client PUSH a message to the server via http, that is just trying to start a message on its route? --- Thank You… Mick Knutson, President BASE Logic, Inc. Enterprise Architecture, Design, Mentoring & Agile Consulting

Camel Spring Remoting throwing RuntimeException question

2009-08-05 Thread akuhtz
Hello, I use a direct endpoint to access a service that throws a RuntimeException and on the calling side I get a UndeclaredThrowableException (with the nested RuntimeException deep in the stack) instead of the expected RuntimeException. Maybe I missed something and this be changed by configurat

Re: bean binding with inheritance & 2.0-M3 camel-http

2009-08-05 Thread Claus Ibsen
Hi Okay I am committing a fix in short time. You can grab it using 2 ways - from the body using the camel type converter, to avoid ugly java type casts - using java type cast to cast the message to HttpMessage // we have access to the HttpServletRequest here and we can grab it if we

Re: Camel Smart Proxy Integration Pattern

2009-08-05 Thread Carlo Camerino
hi, my usecase is somewhat like this, i'm connecting a legacy system via tcp/ip. I plan to multiplex that tcp/ip port by putting in a receiver thread that continuously polls the result. requesting threads can sort of queue their request and wait for the proper reply. while waiting for their reply

Re: Two-Phase-Commit with JCA, Spring, Camel and OC4j

2009-08-05 Thread smilicevics
Hi, is there any solutions to my problem? Sasa smilicevics wrote: > > Hi > > I did that too: > > > >uri="oracle:queue:java:comp/resource/WeborderJmsResourceProvider/Queues/JMSEXAMPLE?maxMessagesPerTask=-1" > /> > >

Re: Route definition with aggregation

2009-08-05 Thread Claus Ibsen
On Wed, Aug 5, 2009 at 12:04 PM, lauri.siltanen wrote: > > Hi, Claus > > Yes, unfortunately, aggregation is required for handling the messages. But I > was able to make it work using the .end() approach. Since that may look > confusing to everyone else, I'll give the direct enpoint a go. > > I did

Re: Route definition with aggregation

2009-08-05 Thread lauri.siltanen
Hi, Claus Yes, unfortunately, aggregation is required for handling the messages. But I was able to make it work using the .end() approach. Since that may look confusing to everyone else, I'll give the direct enpoint a go. I did actually have a "dummy" endpoint in use, much like the direct endpoi

Re: Route definition with aggregation

2009-08-05 Thread Claus Ibsen
Hi Are you sure you want to use an aggregator? When reading it is sounds like you want to do from A -> B -> choice when (X) -> C from(EndpointA) .to(EndpointB) .choice() .when(aggregationPredicate).to(EndpointC) .end(); You can use the "direct" endpoint to link routes together so if yo

Re: bean binding with inheritance & 2.0-M3 camel-http

2009-08-05 Thread Claus Ibsen
Hi Cool I have added a ticket to get it back https://issues.apache.org/activemq/browse/CAMEL-1879 On Wed, Aug 5, 2009 at 10:52 AM, jjb wrote: > > Hi, Claus. > > I built a framework to receive status related messages from a topic as the > route is traversed.  Consider the routes the define Derive

Re: bean binding with inheritance & 2.0-M3 camel-http

2009-08-05 Thread jjb
Hi, Claus. I built a framework to receive status related messages from a topic as the route is traversed. Consider the routes the define DerivedClass -> A -> B -> C. As each segment in the route executes, it sends JAXB/XML messages to a topic that are then forwarded back to the client via a cal

Re: bean binding with inheritance & 2.0-M3 camel-http

2009-08-05 Thread Claus Ibsen
Hi Ah the response may be missing on the HttpMessage. What do you need it for? On Wed, Aug 5, 2009 at 9:51 AM, jjb wrote: > > Hi, Claus. > > Thank you so much for looking into the issue.  My last request has to do > with how to obtain a reference to the HttpServletResponse in the new (>= > 2.0-M

Re: bean binding with inheritance & 2.0-M3 camel-http

2009-08-05 Thread jjb
Hi, Claus. Thank you so much for looking into the issue. My last request has to do with how to obtain a reference to the HttpServletResponse in the new (>= 2.0-M3) Camel API. I can get the HttpServletRequest as you suggested (using HttpMessage), but how do I obtain a reference to the HttpServle

Route definition with aggregation

2009-08-05 Thread lauri.siltanen
I have a bunch of messages that need to be routed from EndpointA to EndpointB, always. In addition, sometimes these messages need to be aggregated to EndpointC. So always to B, sometimes to C. I have tries to achieve this by the following DSL definition: from(EndpointA).choice() .when(aggregat

Re: bean binding with inheritance & 2.0-M3 camel-http

2009-08-05 Thread Claus Ibsen
Hi Thanks for the sample. I can reproduce the issue. The issue is that your base class implements the javax.jms.MessageListener. I will dig into why Camel prefers to invoke this method over the method name specified. On Tue, Aug 4, 2009 at 8:02 PM, jjb wrote: > > Hi. > > Attached is an example