Hi
Did you have any route that consumer the message from the "direct:order" ?
Like this
from("direct:order").xxxx

On Mon Feb 20 18:15:24 2012, kapoor wrote:
Hi I have done a sample test to send object to queue.

  PurchaseOrder order = new PurchaseOrder();
         order.setName("Camel in Action");
         order.setPrice(4995);
         order.setAmount(1);
         ProducerTemplate template = context.createProducerTemplate();
         template.sendBody("test-jms:queue:order.queue", order);

it works fine.
but when i use direct insted of jms.

  template.sendBody("direct:order", order);

I am getting this error. I guess am missing some basic point.

Exception in thread "main" org.apache.camel.CamelExecutionException:
Exception occurred during execution on the exchange: Exchange[Message:
org.apache.camel.example.jmstofile.PurchaseOrder@1c6f579]
        at
org.apache.camel.util.ObjectHelper.wrapCamelExecutionException(ObjectHelper.java:1212)

--
View this message in context: 
http://camel.465427.n5.nabble.com/error-while-using-direct-order-tp5498624p5498624.html
Sent from the Camel - Users mailing list archive at Nabble.com.




--
Willem
----------------------------------
FuseSource
Web: http://www.fusesource.com
Blog:    http://willemjiang.blogspot.com (English)
        http://jnn.javaeye.com (Chinese)
Twitter: willemjiang Weibo: willemjiang

Reply via email to