1.导入jia包
同步请求所用到的包是:
<dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpclient</artifactId> <version>4.5.2</version> </dependency>
异步请求用到的包是:
<dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpasyncclient</artifactId> <version>4.1.2</version>
</dependency>
1.xml
SSOAP 1.1
The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.
POST /ServiceApi.asmx HTTP/1.1
Host: 0.0.0.0
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://www.uradiosys.com/HostAddOrUpdateByOtherSys"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<HostAddOrUpdateByOtherSys xmlns=