ActiveMQ InactivityIOException: Channel was inactive for too (>30000) long 处理方案
来源:互联网 发布:linux复制多个文件 编辑:程序博客网 时间:2024/05/17 04:22
生产服务器上,MQ Produce和consumer端同时报如下错误,导致不能正常工作。
Transport (tcp://132.97.122.168:61616) failed, reason: org.apache.activemq.transport.InactivityIOException: Channel was inactive for too (>30000) long: tcp://132.97.122.168:61616, attempting to automatically reconnect
官网解释如下:
maxInactivityDuration=30000The maximum inactivity duration (before which the socket is considered dead) in milliseconds. On some platforms it can take a long time for a socket to appear to die, so we allow the broker to kill connections if they are inactive for a period of time. Use by some transports to enable a keep alive heart beat feature. Set to a value <= 0 to disable inactivity monitoring.
即:配置JMS连接最大闲置时间(消息服务器无消息)
该wireFormat.maxInactivityDuration 的默认值是30000ms
wireFormat.maxInactivityDuration=0 这样的参数, wireFormat.maxInactivityDuration是心跳参数。
避免ActiveMQ在一段时间没有消息发送时抛出 "Channel was inactive for too long"异常。该异常会关闭连接,虽然client端会重连成功,但是不能发送数据,然后继续报下面异常:
2014-10-30 00:49:49 [ ActiveMQ Task-3:529216111 ] - [ INFO ] Successfully reconnected to tcp://132.97.122.168:616162014-10-30 00:49:49 [ ActiveMQ Transport: tcp:///132.97.122.168:61616@41298:529216129 ] - [ WARN ] Transport (tcp://132.97.122.168:61616) failed, reason: java.net.SocketException: Connection reset, attempting to automatically reconnect
解决方案:wireFormat.maxInactivityDuration=0,禁用InactivityMonitor
即改成如下格式:
failover:(tcp://172.26.7.15:61616?wireFormat.maxInactivityDuration=0,tcp://172.26.7.17:61616?wireFormat.maxInactivityDuration=0,tcp://172.26.7.18:61616?wireFormat.maxInactivityDuration=0)
改之前:
禁用后:
0 0
- ActiveMQ InactivityIOException: Channel was inactive for too (>30000) long 处理方案
- Active MQ InactivityIOException: Channel was inactive for too long
- ACTIVEMQ Channel was inactive for too (>30000)long
- Channel was inactive for too (>30000)long
- amq报错Channel was inactive for too (>30000)long
- Specified key was too long
- 关于activeMq在本地测试报错org.apache.activemq.transport.InactivityIOException: Cannot send, channel has alrea
- 关于MountService( 546): Waiting too long for mReady处理
- laravel Specified key was too long 解决方案
- Date too long for column.
- Data too long for column
- OPENFIRE+MYSQL5.6安装中遇见Specified key was too long; max key length is 767 bytes openfire处理办法
- MySQL中ERROR 1071 (42000): Specified key was too long; max key length is 767 bytes错误的处理
- Data truncation: Data too long for column 'name' at row 1的处理
- MYSQL---Data too long for column 'sex' at row 1”错误处理办法
- data too long for column 解决方案
- 解决data too long for column”错误
- data too long for column 问题
- iOS 开发之使用CocoaPods更新第三方出现“HEADER_SEARCH_PATHS `OTHER_LDFLAGS`……”问题解决方案
- OpenGL编辑
- 企业qq与私人qq同时登陆的问题
- C/C++
- JIRA安装破解汉化
- ActiveMQ InactivityIOException: Channel was inactive for too (>30000) long 处理方案
- Unity3D PC版本打包
- ios ALAsset和ALAssetRepresentation详解
- POJ 3084
- WEKA使用教程(经典教程转载)
- 百度笔试题:malloc/free与new/delete的区别
- Android图片处理:识别图像方向并显示
- POJ 2135(Farm Tour-费用流)[Template:费用流 V2]
- 高通AR增强现实Unity3D