仅使用 wsdl 在没有 WebService 的情况下创建 SOAP 消息

SOAP Message creation without a WebService just with wsdl

我在 Spring JMS 项目中有一个 wsdl 文件,我需要在其中创建一个 XML 以发送到 queue。这个 xml 应该看起来像一个包含 Header Body 和整个信封的 SOAP 消息。我不明白如何不实现 SOAP WebService 但仍然创建 XML SOAP 结构。我不想使用 SOAP 元素 类 创建整个结构,我必须在其中编写大量代码,并且每次如果我的 Java Object 更新,我也必须更新此实现,谢谢帮助。

请参阅 Spring Web Services Reference Manual(特别是客户端的 JMS 传输)。

For sending messages over JMS, Spring Web Services provides the JmsMessageSender. This class uses the facilities of the Spring framework to transform the WebServiceMessage into a JMS Message, send it on its way on a Queue or Topic, and receive a response (if any).

To use the JmsMessageSender, ...