简体   繁体   English

如何将现有的 SOAP Web 服务调用到 REST API Z38008DD81C2F4D79185ECF6E0CE8AF1 启动应用程序

[英]How to invoke existing SOAP webservice into REST API Spring boot application

I have a Rest Spring boot application, I need to invoke external SOAP webservice in my Rest Spring boot application - similar question asked in stackoverflow - Calling a SOAP service using REST service but didn't get any exact steps. I have a Rest Spring boot application, I need to invoke external SOAP webservice in my Rest Spring boot application - similar question asked in stackoverflow - Calling a SOAP service using REST service but didn't get any exact steps. One blog I found the solution but don't know whether it right approach or not - https://docs.oracle.com/cd/E19340-01/820-6767/aeqgc/index.html一篇博客我找到了解决方案,但不知道它是否正确 - https://docs.oracle.com/cd/E19340-01/820-6767/aeqgc/index.Z9A535FDC7AD8E2FC5

Let me know if anyone knows the solution.如果有人知道解决方案,请告诉我。 Whether need to create wsdl in Spring boot rest application or directly convert the json to xml and invoke the endpoint? Whether need to create wsdl in Spring boot rest application or directly convert the json to xml and invoke the endpoint?

The WSDL is provided by the SOAP Web service. WSDL 由 SOAP Web 服务提供。 You can get it by visiting its WSDL endpoint url.您可以通过访问其 WSDL 端点 url 来获取它。

The idea is that once you get the WSDL, copy it to your project folder and then use some maven plugin to generate a SOAP client from the WSDL. The idea is that once you get the WSDL, copy it to your project folder and then use some maven plugin to generate a SOAP client from the WSDL. Here is the spring official guide for how to do it.这是spring 官方指南,了解如何操作。

You operate the generated client in the java object level and it will help to format the SOAP request in the correct XML format and then send out.So you do not need to manually create the XML request by yourself. You operate the generated client in the java object level and it will help to format the SOAP request in the correct XML format and then send out.So you do not need to manually create the XML request by yourself.

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM