【发布时间】:2020-02-14 06:16:30
【问题描述】:
我必须通过点击休息服务向 IBM MQ 发送消息。下面是我使用 Camel XML DSL 编写的代码。
<rest path="/basePath">
<post uri="/path" consumes="application/xml" produces="application/xml">
<to uri="ibmmq:QUEUE.NAME"/>
</post>
</rest>
当我尝试发布消息时,我收到以下异常
org.apache.camel.RuntimeExchangeException: Failed to resolve replyTo destination on the exchange
post 方法是否期望从 QUEUE 返回响应,以便它可以响应休息客户端? 我只需要post service回复200,如果消息成功产生到QUEUE,否则回复500。 如何解决这个问题?
【问题讨论】:
-
我也在尝试实现 IBM MQ Producer,如果有 Github 中的示例代码,请链接
标签: apache-camel spring-camel camel-http