camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Babak Vahdat <>
Subject Re: camel-quickfix RequestReplyExample
Date Wed, 01 May 2013 04:23:13 GMT
Hi Steve,

Sorry for the late answer but just for the record and also maybe other users
who may follow this thread:

The reason for the behavior you were observing has nothing to do with the
MEP itself but a bug being already fixed:

So that if yo would try the same now (e.g on the trunk code) then the
behaviour you're describing below is not given anymore.


stevebate wrote
> On Feb 27, 2013, at 3:12 AM, "Babak Vahdat [via Camel]" &lt;

> ml-node+s465427n5728204h85@.nabble

> &gt; wrote:
>> Hi Steve 
>> Thanks for looking into this. Unfortunately the provided patch causes
>> regressions by some pre-existing tests of this component. I've provided
>> the details of this into the ticket itself, so let's continue the
>> conversation inside JIRA itself to avoid making noise here @ the user
>> forum. 
> Sorry. I should have run the unit tests before submitting the patch. I've
> submitted an updated patch with changes to the unit test mock setup for
> the new Exchange copy behavior and the sessionID reversal in the
> MessagePredicate. I agree we can continue any patch-related discussion
> using Jira. However, the following discussion might be of general
> interest.
>> And regarding your surprise maybe the following thread could be helpful
>> for a better understanding: 
>> In general if the MEP is InOnly and a service invocation (through a Camel
>> Producer) returns a reply, then a good practice is to set the reply as
>> the body of the IN message. This would make the next processor in chain
>> to make use of this IN object as it say here: 
> This is confusing to me because the Exchange is now InOut, not InOnly. I
> did some experimentation and found that this route,
> from("quickfix:examples/inprocess.cfg?sessionID=FIX.4.2:MARKET->TRADER&exchangePattern=InOut")
> .filter(header(QuickfixjEndpoint.MESSAGE_TYPE_KEY).isEqualTo(MsgType.ORDER_STATUS_REQUEST))
>     .bean(new MarketOrderStatusService())
>     .bean(new QuickfixjMessageJsonPrinter());
> required the Exchange copy for the InOut MEP because the inbound message
> is overwritten by subsequent processors. However, 
> the following route does not require the copy (the
> QuickfixjMessageJsonPrinter bean has been removed).
> from("quickfix:examples/inprocess.cfg?sessionID=FIX.4.2:MARKET->TRADER&exchangePattern=InOut")
> .filter(header(QuickfixjEndpoint.MESSAGE_TYPE_KEY).isEqualTo(MsgType.ORDER_STATUS_REQUEST))
>     .bean(new MarketOrderStatusService());
> Does this mean that the QuickfixjConsumer is sometimes required to copy
> the inbound Exchange (InOut MEP) and sometimes not,
> depending on the route components that follow it? If so, the safe behavior
> is to always copy the Exchange, but it seems that it should
> logically not need to do that for an InOut MEP.
>> if there is no out message then the in message is used instead

View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message