Hi Glen,

Glen Mazza wrote:
Hello, for the JMS Component, where do I place the options[1] (those settings after the "?") -- within the from("jms:FOO.BAR?options...") of the route or within the Template.sendBody("jms:FOO.BAR?options...") or both places or does it depend on the option I'm setting?
You need to place the option into these two place.
As these two endpoint will create a producer and a consumer separately.


For example, to add jmsMessageType=Object, I see it could go in two places but am not sure which one is correct:

     ProducerTemplate template = context.createProducerTemplate();
     MyObject myObj = new MyObject();
template.sendBody("jms:queue:numbersToDouble2?jmsMessageType=Object", myObj);


and/or, within the route:

     from("jms:queue:numbersToDouble2?jmsMessageType=Object")
     .marshal(jaxbFormat)
     .to(....), etc.


Thanks,
Glen

[1] http://camel.apache.org/jms.html#JMS-Options


Willem

Reply via email to