Hi,

I have a WSDL with both Request-Reponse and One-Way operations for the same
binding.

When using CXF i have for each "operation" a method to implement (so code
for OneWay - RequestReply is easy to split).

When using CAMEL/CXF, i have a single route to handle both In-Only and
In-Out.

Previously i had ONLY inOnly messages so a simple route with a simple
myProcessor like :

from("cxf:bean:myEndpoint")
        .process(myProcessor)
        .to("activemq:queue:myQueue");

was enough.



But with mix of InOnly InOut, myProcessor should become more complex and i
will add at least one another processor to handle response and errors.

I would use a Message Router based on operation :

from("cxf:bean:myEndpoint")
            .choice()
                .when(header("operation").isEqualTo("operation1"))
                    .to(processor1)
                .when(header("operation").isEqualTo("operation2"))
                    .to(processor2)
                .otherwise()
                    .to(processor3);

But if i have a lot of operations, the route will be a nightmare.

What is the best way to mix both request/Reply and InOnly (in order to ease
understanding and coding) with Camel ?

Regards

Hervé

Reply via email to