You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fx-dev@ws.apache.org by Denis Schlesinger <sc...@ecs-gmbh.de> on 2005/07/27 11:36:39 UTC

[Sandesha] Sandesha replaces payload

The next problem came sooner that I thought...

 

Somehow my <soapenv:body> element is completely replaced by Sandesha
with the following:

 

<soapenv:Body><wsrm:CreateSequence><wsrm:AcksTo><wsa:Address>http://192.
168.1.146:9090/axis/services/RMService</wsa:Address></wsrm:AcksTo></wsrm
:CreateSequence></soapenv:Body>

 

In my code I add a soap envelope to the Call object when calling the
'invoke'-method which is replaced by Sandesha then:

 

SOAPEnvelope env = new SOAPEnvelope();

        // Always needed namespaces

        env.addNamespaceDeclaration("xsd",
"http://www.w3.org/2001/XMLSchema");

        env.addNamespaceDeclaration("xsi",
"http://www.w3.org/2001/XMLSchema-instance");

        

        // Add the XML request document

        env.addBodyElement(new
SOAPBodyElement(requestDocument.getDocumentElement()));

        

        Document soapEnvelope = env.getAsDOM().getOwnerDocument();

        writeXMLDocToFS(soapEnvelope, "asyncRequestSOAPDoc.xml");

 

        // Make it asynchronous

        SandeshaContext ctx = new SandeshaContext();

      ctx.initCall(call,
this.webService.getPort().getAddress(),this.methodToInvoke,
Constants.ClientProperties.IN_OUT);

      ctx.setLastMessage(call);

        

      responseSOAPDoc = call.invoke(env).getAsDocument();

        

      ctx.endSequence();

 

Thanks,

Denis