Java Web 服务: WS-Security 的大开销
2009-11-05 00:00:00 来源:WEB开发网清单 1 展示了一个对服务的示例请求,以及随后的响应(为适应页面宽度重新调整了格式):
清单 1. 示例请求和响应
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<ns1:matchQuakes xmlns:ns1="http://ws.sosnoski.com/seismic/types">
<ns1:min-date>2001-08-08T16:31:05.752+00:00</ns1:min-date>
<ns1:max-date>2001-08-14T23:51:31.499+00:00</ns1:max-date>
<ns1:min-long>160.4685</ns1:min-long>
<ns1:max-long>178.19693</ns1:max-long>
<ns1:min-lat>-42.423557</ns1:min-lat>
<ns1:max-lat>-30.44976</ns1:max-lat>
</ns1:matchQuakes>
</soapenv:Body>
</soapenv:Envelope>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<ns1:results xmlns:ns1="http://ws.sosnoski.com/seismic/types" count="9">
<ns1:result-set>
<ns1:area-name>New Zealand Region</ns1:area-name>
<ns1:regions count="0">
<ns1:region ident="rgn159" index="159">NORTH ISLAND,
NEW ZEALAND</ns1:region>
<ns1:region ident="rgn160" index="160">OFF E. COAST OF N. ISLAND,
N.Z.</ns1:region>
</ns1:regions>
<ns1:quakes count="9">
<ns1:quake time="2001-08-11T09:52:54.000+00:00" millis="1000"
latitude="-37.6499" longitude="177.74" depth="83.0" magnitude="4.4"
method="ML" region="rgn160"/>
<ns1:quake time="2001-08-11T09:52:55.000+00:00" millis="0"
latitude="-37.71" longitude="177.77" depth="70.0" magnitude="4.5"
method="ML" region="rgn160"/>
<ns1:quake time="2001-08-11T15:02:47.000+00:00" millis="5600"
latitude="-38.0429" longitude="175.632" depth="299.8" magnitude="4.6"
method="ML" region="rgn159"/>
<ns1:quake time="2001-08-12T07:42:41.000+00:00" millis="7000"
latitude="-37.97" longitude="175.97" depth="289.0" magnitude="4.3"
method="MB" region="rgn159"/>
<ns1:quake time="2001-08-12T22:37:58.000+00:00" millis="5600"
latitude="-38.3839" longitude="176.121" depth="163.2" magnitude="4.0"
method="ML" region="rgn159"/>
<ns1:quake time="2001-08-12T23:25:09.000+00:00" millis="6700"
latitude="-39.9559" longitude="176.115" depth="76.0" magnitude="4.0"
method="ML" region="rgn159"/>
<ns1:quake time="2001-08-13T05:10:07.000+00:00" millis="4300"
latitude="-37.5859" longitude="176.651" depth="189.0" magnitude="4.3"
method="ML" region="rgn159"/>
<ns1:quake time="2001-08-14T02:43:18.000+00:00" millis="2900"
latitude="-38.3699" longitude="175.902" depth="193.4" magnitude="4.5"
method="ML" region="rgn159"/>
<ns1:quake time="2001-08-14T18:02:35.000+00:00" millis="5400"
latitude="-37.8159" longitude="176.375" depth="193.3" magnitude="4.5"
method="ML" region="rgn159"/>
</ns1:quakes>
</ns1:result-set>
</ns1:results>
</soapenv:Body>
</soapenv:Envelope>
更多精彩
赞助商链接