Mule ESB中的重新连接策略 [英] Reconnection strategy in Mule ESB

查看:673
本文介绍了Mule ESB中的重新连接策略的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试验证文档中提到的Mule ESB中的重新连接策略。



我已经设置了标准的重新连接策略,重试atatts为5和一些超时。



(我的终点无法到达,因为故意停止测试场景)。



我在Mule控制台中有例外:
异常堆栈是:
1.连接被拒绝:connect(java.net.ConnectException)
java.net.DualStackPlainSocketImpl:-2(null)
2.无法通过端点路由事件:DefaultOutboundEndpoint



然后我将重新连接策略更改为永远连接并尝试了它。
在这种情况下我也得到了同样的错误。



我的qstn是,如果我设置'永远连接'功能,那么我希望应用程序尝试重新连接直到它成功。但这并没有发生。



而且在第一种情况下,如果我的重试尝试是5,那么我没有看到任何提到重试尝试次数的问题。



任何人都可以更好地解释这个重新连接属性是否真的在Mule ESB 3.4中工作。



在此先感谢。

解决方案

HTTP是一种断开连接的协议:重新连接策略仅适用于连接的协议,如JMS或JDBC。 / p>

我看到错误出现在出站端点,所以我觉得你期望Mule 重试发送,而不是重新连接传输。



重试的一种方法是使用直到成功的消息处理器。 / p>

I am trying to verify the Reconnection strategy in Mule ESB as mentioned in the documentation.

I have set the standard Reconnection strategy with retry attemts as 5 and with some timeout.

(My end point is not reachable, as intentionally stopped it to test the scenario).

I have the exception in the Mule console as: Exception stack is: 1. Connection refused: connect (java.net.ConnectException) java.net.DualStackPlainSocketImpl:-2 (null) 2. Failed to route event via endpoint: DefaultOutboundEndpoint

And then I changed the reconnection strategy to 'connect forever' and tried it. In this case also I got the same error.

My qstn is, if I set the 'Connect forever' feature, then I expect the application to try for re connect untill it gets succeeded. but this is not happenning.

And also in the first scenario, if my retry attemps are 5, then I dont see any loogs mentioning the number of retry attempts made.

Can any one plese explain it in better way whether this reconnection property is actually working in Mule ESB 3.4.

Thanks in advance.

解决方案

HTTP is a disconnected protocol: the reconnection strategies only work for connected protocols, like JMS or JDBC.

I see the error is in an outbound endpoint so I have the impression you are expecting Mule to retry the dispatch, not reconnected the transport.

One way to do retries is to use the until-successful message processor.

这篇关于Mule ESB中的重新连接策略的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆