Hi:
The camel 2.1's pipeline patter's MEP is InOnly default. But the result of
following route is different, if I using inOnly() processor in route vs
using default;

I tried it using a simple sample: send a message to a direct endpoint, which
body is number=1, a route receive the message and increase the message's
body twice by a processor, then send to a mock endpoint;

The increase number process's code is:

Class IncreaseProcessor{
        void process(MessageExchange me)
        {
                Integer result= Me.getIn().getBody() + 1;
                Me.getOut().setBody(result);
        }
}

1): following rout using inOnly() processor , and mock endpoint's return
ME's in.body=3, out=Null

from("direct:inOnlyUsingProcessor").inOnly().process(outProcessor).process(o
utProcessor).to("mock:result");


2) following route using default inOnly, and mock's return ME's in.body=3,
out.body=2. 
from("direct:inOnlyDefault").process(outProcessor).process(outProcessor).to(
"mock:result");

So why the result has a out message and it's body=2, it should be same as
the first route(out=null);





Reply via email to