ActiveMQ NMS: connection.start() hangs with Failover protocol when broker is down

浪子不回头ぞ 提交于 2019-12-04 12:43:15
GustavLatte

After mining google results fI found this thread

Tim Bish answered the developer there that in NMS there is a prefix transport.* that need to added to all transport properties.

my original uri was:

failover://(tcp://A,tcp://B)?randomize=true&startupMaxReconnectAttempts=1&timeout=2000

and now my URI is (pay attention on transport.* prefix):

failover://(tcp://A,tcp://B)?transport.randomize=true&transport.startupMaxReconnectAttempts=1&transport.timeout=2000

which is working and I handle the exception thrown and continue with my App.

Enjoy

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!