camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Raul Kripalani (JIRA)" <>
Subject [jira] [Created] (CAMEL-5953) Java DSL: unmarshal() inside choice() blocks adding more conditions
Date Thu, 10 Jan 2013 20:58:12 GMT
Raul Kripalani created CAMEL-5953:

             Summary: Java DSL: unmarshal() inside choice() blocks adding more conditions
                 Key: CAMEL-5953
             Project: Camel
          Issue Type: Bug
    Affects Versions: 2.10.3
            Reporter: Raul Kripalani

This routing code leads to the exception below:

        .when(simple("${body} == 'Please do not fail'"))


Caused by: java.lang.ClassCastException: org.apache.camel.model.RouteDefinition cannot be
cast to org.apache.camel.model.ChoiceDefinition
	at org.apache.camel.model.ProcessorDefinition.endChoice(
	at com.mycompany.MyRoute.configure(
	at org.apache.camel.builder.RouteBuilder.checkInitialized(
	at org.apache.camel.builder.RouteBuilder.configureRoutes(
	at org.apache.camel.builder.RouteBuilder.addRoutesToCamelContext(

Also happens if we try to add another when instead of an otherwise.

Tried using end(), endParent(), but they all lead to the same exception. 

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message