camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sashika <sashik...@gmail.com>
Subject Re: .choice(), .when() not working as expected in the camel route
Date Tue, 17 May 2016 02:29:27 GMT
Did you try removing . endChoice() and just using end?





On Thu, May 12, 2016 10:13 PM, Quinn Stevenson quinn@pronoia-solutions.com wrote:
I tried this route with a test, and I’m not sure where the body is supposed to
be set to “Error decoding HL7”. Given I can’t make the route set the body to the
required value (unless that’s what I actually send), it looks like the choice is
working correctly.




Can you insert a log statement right after the from to log the body to see what
it actually is?




> On May 11, 2016, at 9:44 AM, Kriti <kriti0788@gmail.com> wrote:

>

> Hi,

>

> I have a camel route like this -

>

> public void configure() {

>

> -------------------------

> -------------------------

>

> from('mina2:tcp://'+ incomingHL7Listener.getIp() + ':' +

> incomingHL7Listener.getPort() +'?codec=#rcmhl7codec')

> .choice()

> .when(body().isEqualTo("Error decoding

> HL7")).to('direct:failure').endChoice()

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message