You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by manoj <ma...@gmail.com> on 2014/10/14 15:54:36 UTC
Apache Camel - Messages are not being processed successfully if the
route is activated using JMX console
I am using Camel "CronScheduledRoutePolicy" to keep my route active between
certain hours.
CronScheduledRoutePolicy policy = new CronScheduledRoutePolicy();
policy.setRouteStartTime("0 0 9 * * ?");
policy.setRouteStopTime("0 0 18 * * ?");
from("jms:inboundqueue").routePolicy(policy).noAutoStartup()
---
Since 'noAutoStartup' is set, it doesn't start the route when the server is
restarted between 9 and 18 hrs.
So, in this case I am using JMX console to start the route, but the
messages are failing with "org.apache.camel.CamelExecutionException:
Exception occurred during execution on the exchange".
when I debugged camel code, I have seen the following -
"/org.apache.camel.InvalidPayloadException, No body available of type:
com......Caused by: [org.apache.camel.TypeConversionException - Error during
type conversion from type: byte[] to the required type:
com.api.jms.generated.PurgeJms with value [B@7376f132 due
com.api.jms.generated.PurgeJms$JaxbAccessorF_purgeTargetIds cannot be cast
to com.sun.xml.internal.bind.v2.runtime.reflect.Accessor]"/
But the same messages are processed successfully if the route is not
activated using JMX but let it start automatically at the mentioned time.
Is there anything that I need to do when I start the route manually with JMX
console ?
--
View this message in context: http://camel.465427.n5.nabble.com/Apache-Camel-Messages-are-not-being-processed-successfully-if-the-route-is-activated-using-JMX-consoe-tp5757560.html
Sent from the Camel - Users mailing list archive at Nabble.com.