Hi,

I've got a problem with double <soap:Envelope> and <soap:Body> tags in my cxf bc component. The idea of my my sa is to translate a message from one soap format to another.
The cxfbc configuration:

<cxfbc:provider wsdl="classpath:service_v1.wsdl"
                    locationURI="http://localhost:8080/my-ws/ws";
                    interfaceName="aaa:ImplPort2"
                    service="aaa:myService"
                    endpoint="ImplPort"
                    useJBIWrapper="false"
                    useSOAPEnvelope="true">
</cxfbc:provider>


<cxfbc:consumer wsdl="classpath:service_v2.wsdl"
                    targetService="test:AdapterService"
                    targetEndpoint="myEndpoint"
                    useJBIWrapper="false"
                    useSOAPEnvelope="false"
                    locationURI="https://0.0.0.0:8190/test/testService/";
                    busCfg="ssl.xml">
</cxfbc:consumer>


Then I use camel and processors to translate the message:


 
from("jbi:endpoint:http://test.pl/test/RoleAnalyzerAdapterService/RoleAnalyzerEndpoint";)
                .to("log:entrance")
                .choice()
                .when(xpath(PROPER_METHOD_INVOKED)))
                .process(new MyTranslator())
                .to("jbi:endpoint:{cxf-bc-provider_endpoint}")
                .otherwise()
                .to("log:wrong_request")
                .setBody(constant(SoapResponseMessages.WRONG_METHOD));


and as a result I get almost good soap (but packed again in soap:Envelope/soap:Body):

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";>
<soap:Body>
<soap:Envelope>
<soap:Body>
<!--response here  -->
</soap:Body>
</soap:Envelope>
</soap:Body>
</soap:Envelope>


Am I doing something wrong, maybe the component should be configured in other way or should I use a processor for getting the body from response and then send it back?

apache-servicemix 3.6.0-fuse-00-35




Reply via email to