camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From contactreji <contactr...@gmail.com>
Subject Re: Body is null exception when producing JMS messages from a Quartz endpoint
Date Thu, 24 Oct 2013 12:50:52 GMT
You need to initialized the body with some value before sending it to some component wen route
is started with timer or quartz 

You can set some arbitory value by using <setBody> tag in your route.  Sending camel
exchange with null body to some camel components generated errors.

Refer setBody tag examples on Google 

"berdoni [via Camel]" <ml-node+s465427n5742072h11@n5.nabble.com> wrote:

>
>
>Hi,
>
>I have the the following route:
>from("quartz://MyTrigger/TriggerRouteStart?cron=0+0/5+*+*+*+?")
>.routeId("TriggerRouteStart")
>.to("activemq:queue:TriggerRouteStart");
>
>This route should trigger every 5mins and put a message to TriggerRouteStart
>queue however I get the following error. Shall I set the body before sending
>any message to the Queue? I see in Camel documentation the following example
>route which is similar:
>from("quartz://myGroup/myTimerName?cron=0+0/5+12-18+?+*+MON-FRI").to("activemq:Totally.Rocks");
>
>Here is my exception:
>ERROR|2013-10-23 15:20:59,026|DefaultQuartzScheduler-camel_Worker-10|               
>QuartzEndpoint - Error processing exchange. Exchange[Message: [Body is
>null]]. Caused by: [org.quartz.JobExecutionException -
>org.apache.camel.CamelExecutionException: Exception occurred during
>execution on the exchange: Exchange[Message: [Body is null]]]
>INFO |2013-10-23 15:20:59,027|DefaultQuartzScheduler-camel_Worker-10|                
 
>JobRunShell - Job DEFAULT.quartz-endpoint14 threw a JobExecutionException: 
>org.quartz.JobExecutionException: org.apache.camel.CamelExecutionException:
>Exception occurred during execution on the exchange: Exchange[Message: [Body
>is null]] [See nested exception: org.apache.camel.CamelExecutionException:
>Exception occurred during execution on the exchange: Exchange[Message: [Body
>is null]]]
>
>
>
>
>_______________________________________________
>If you reply to this email, your message will be added to the discussion below:
>http://camel.465427.n5.nabble.com/Body-is-null-exception-when-producing-JMS-messages-from-a-Quartz-endpoint-tp5742072.html
>
>To unsubscribe from Camel - Users, visit http://camel.465427.n5.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=465428&code=Y29udGFjdHJlamlAZ21haWwuY29tfDQ2NTQyOHwxMDA0OTE4MjMz



--
View this message in context: http://camel.465427.n5.nabble.com/Body-is-null-exception-when-producing-JMS-messages-from-a-Quartz-endpoint-tp5742072p5742126.html
Sent from the Camel - Users mailing list archive at Nabble.com.
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message