When using axis 1.4 to call a legacy web service we got the not so explaing error ”no xml was provided”. The fault was found (after some wireshark fun) to be that the call was done using chunked encoding.
Now then, setting the chunked encoding would normally be done by overriding the createCall method in org.apache.axis.client.service by using call.setProperty(HTTPConstants.HEADER_TRANSFER_ENCODING_CHUNKED, false); but doing that changed nothing. What did work was doing:
Map<String, Object> headers = (Hashtable<String, Object>) call.getProperty(HTTPConstants.REQUEST_HEADERS);
if (headers == null) {
headers = new Hashtable<String, Object>();
}
headers.put(HTTPConstants.HEADER_TRANSFER_ENCODING_CHUNKED, false);
call.setProperty(HTTPConstants.REQUEST_HEADERS, headers);