If I remember right, we had/have a problem with a 'choice' in another
'choice'.
Could you please change your route in this way (I also removed some blanc
which could be the problem):
<route>
<from uri="direct:parsedData" />
<log message="Received xml from MocC ${body}
[${in.header.inputDataType}] [${header.CamelFileNameOnly}]"/>
<choice>
<when>
<simple>${header.batchSize} == 2000</simple>
<log message="processing batch of size == 2000
---[${header.inputDataType}]"/>
<to uri="direct:subChoice" />
</when>
</choice>
</route>
<route>
<from uri="direct:subChoice" />
<choice>
<when>
<simple>$'header.inputDataType' = 'TAP'</simple>
<log message="persisting TAP file ${header.CamelFileNameOnly}"/>
<threads executorServiceRef="threadpool2">
<to uri="jms:queue:test_request_2"/>
<marshal ref="gzip"/>
<to
uri="file:C://Camel//tap//out?fileName=${header.CamelFileNameOnly}.gz"/>
</threads>
</when>
<when>
<simple>$'header.inputDataType' = 'TDR'</simple>
<log message="persisting TDR file ${header.CamelFileNameOnly}"/>
<threads executorServiceRef="threadpool2">
<to uri="jms:queue:test_request_1"/>
<marshal ref="gzip"/>
<to
uri="file:C://Camel//tdr//out?fileName=${header.CamelFileNameOnly}.gz"/>
</threads>
</when>
</choice>
</route>
Best,
Christian
On Mon, May 21, 2012 at 9:26 PM, ebinsingh <
[email protected]> wrote:
> Adding to the above post...
>
> I changed assert statement to the below, but still no luck (it should fail
> but it's not)
> *getMockEndpoint("mock:dataToParse").assertIsSatisfied();*
>
> Appreciate your help.
>
> Thanks & regards,
> Ebe
>
> --
> View this message in context:
> http://camel.465427.n5.nabble.com/Issue-Choice-not-working-tp5712978p5713135.html
> Sent from the Camel - Users mailing list archive at Nabble.com.
>