shell - 使用 shell 脚本调用 tibco soap webservice
问题描述
我正在尝试使用 curl 通过 shell 脚本调用基于 TIBCO 肥皂的 Web 服务。我得到 200 ok 的响应,但没有在 response.xml 中得到输出
Tibco webservice 部署在三个实例中。我试图点击其中一个实例并检索响应,但我得到的内容长度为 0。
我尝试使用 curl 和 wget 调用 webservice 并检索响应,但内容长度为 0。
下面是 curl 命令:
curl -v --header "Content-Type: text/xml;charset=UTF-8" --header "SOAPAction: "/ServiceImplV1.0/getInfo"/" --data @request2.xml http://sfapt-ap98t:4121/service/dataservice -o response.xml
request2.xml
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:v1="http://www.greatclips.com/ghf/tck/service/v1.0">
<soapenv:Header/>
<soapenv:Body>
<v1:GetBaseLineRequest>
<!--Optional:-->
<UniqueRequestIdentifier>?</UniqueRequestIdentifier>
</v1:GetBaseLineRequest>
</soapenv:Body>
</soapenv:Envelope>
Response Hostname was NOT found in DNS cache
* Trying 10.215.13.217...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* Connected to dlfapt-ap98a (10.215.13.217) port 6121 (#0)
> POST /service/addataservice HTTP/1.1
> User-Agent: curl/7.37.0
> Host: dlfapt-ap98a:6121
> Accept: */*
> Content-Type: text/xml;charset=UTF-8
> SOAPAction: /ServiceImplV1.0/getBaseLineDetails/
> Content-Length: 323
>
} [data not shown]
来自服务器的响应:
* upload completely sent off: 323 out of 323 bytes
< HTTP/1.1 200 OK
< Content-Length: 0
< Date: Fri, 19 Jul 2019 17:57:45 GMT
* Server is not blacklisted
< Server:
<
100 323 0 0 100 323 0 19383 --:--:-- --:--:-- --:--:-- 35888
* Connection #0 to host dlfapt-ap98a left intact
解决方案
推荐阅读
- c# - 无法防止双重输入 c# listview
- powershell - 网络使用 x: https://server/path vs new-psDrive x https://server/path
- kotlin - Divider 可组合在放置在带有 HorizontalScroll 修饰符集的可组合内时变得不可见。这是一个错误吗?
- json - 是否可以在需要时延迟加载几个小 json 文件,而不是加载 angular 中的大 json 文件?
- docker - Docker:复制失败:在构建上下文中找不到文件或被 .dockerignore 排除
- domain-driven-design - 防止项目属性在包含在订单中后被修改
- swift - 可以为 UICollectionView(列表样式)自定义 .outlineDisclosure 选项的位置和布局吗?
- javascript - 为什么我的“更改”事件没有按预期工作?
- ssl - influxdb 2.0 证书验证失败:证书已过期 (_ssl.c:1129)
- angular - 使用外部服务器端后端设置 Angular