Hi,
I am using apache axis tool behind the firewall to communicate with the web 
services hosted in micro soft .net
I have created all the required stubs using WSDL2Java 

One of the stub class i have modified is as below to add the wsa:action, wsa:To 
and UserTokens at run time

org.apache.axis.client.Call _call = createCall();
        _call.setOperation(_operations[1]);
/* To add the wsa:action and wsa:To elements */

        _call.setUseSOAPAction(true);
        
_call.setSOAPActionURI("https://KDSL.com/KDSLServices/KDSLGateWay/AddNewSupplier";);
        
_call.setTargetEndpointAddress("https://gateway.kdsl.com/kdslservices/kdsl.asmx";);
 
/* To add the usertoken */
        
_call.setProperty(UsernameToken.PASSWORD_TYPE,WSConstants.PASSWORD_TEXT);
        _call.setProperty(WSHandlerConstants.USER, "testuser");

But i am getting "Axis Fault Server was unable to process request. --> The 
message must contain a wsa:To header"

Am i doing it in the right way ? Please advice

Thanks,
Jayadev




Reply via email to