【发布时间】:2015-09-17 21:53:44
【问题描述】:
我在 Spring 集成中遇到了 StoredProcOutboundGateway 的回复超时属性问题。我已经阅读了文档,它说在 Gateway 的直接通道的情况下回复超时将不起作用。但如果是外部集成网关,即 StoredProcOutboundGateway,它会说
"当发送到 DirectChannel 时,调用将发生在发送者的线程中,因此发送操作失败可能是由更下游的其他组件引起的"
根据我的设计,我的 StoredProcOutboundGateway 回复正在发送到直接通道。在回复超时到期后,StoredProcOutboundGateway 会抛出异常吗? .为了重新创建这个场景,我在 StoredProcOutboundGateway.handleRequestMessage 方法的第一行放置了一个调试点并等待配置的回复超时,但它没有抛出任何异常,即使在配置的时间之后它也返回了成功的响应。
<int:gateway id="idGateway" service-interface="Gateway">
<int:method name="getStoreProcData" request-channel="store.req.channel" reply-channel="store.reply.channel" />
</int:gateway>
<int-jdbc:stored-proc-outbound-gateway stored-procedure-name="GE_PKG.GET_PRC"
ignore-column-meta-data="true" reply-timeout="2000" request-channel="store.req.channel" reply-channel="store.reply.channel" is-function="false"
............other cursor config
</int-jdbc:stored-proc-outbound-gateway>在此输入代码
<int:channel id="store.req.channel" />
<int:channel id="store.reply.channel" />
Spring-Integration V4..1.2 DB oracle ojdbc6
【问题讨论】:
标签: spring-integration spring-jdbc