zoukankan      html  css  js  c++  java
  • 没有连接的AMQP / RabbitMQ通道何时死亡?(when does an AMQP/RabbitMQ channel with no connections die?)

    I have a simple RabbitMQ test program randomly enqueuing messages, and another reading them, all using Spring-AMQP. If the consumer dies (for example killing a process without having a chance to close its connection or channel), any messages that it had not acknowledged appear to remain unacknowledged forever.

    I have seen a number of references (for example this question) that say that the channel dies when it has no connections, and that remaining unack'd messages will be redelivered. That's not the behaviour I see - instead I get a growing list of channels marked IDLE and a growing list of connections marked running but with no activity.

    Is there some configuration required to notice that connections are dead once the process has been killed?

    EDIT: I was running the rabbitmq server inside a VirtualBox VM, which apparently doesn't manage dead inbound connections correctly over NAT. This works just fine with the mq server running directly on the physical host.

    解决方案

    Answering to close. This turns out not to be a real issue.

    I was running the rabbitmq server inside a VirtualBox VM, which apparently doesn't manage dead inbound connections correctly over NAT. This works just fine with the mq server running directly on the physical host.

    问 题

    我有一个简单的RabbitMQ测试程序随机排队消息,另一个读取它们,都使用Spring-AMQP。如果消费者死亡(例如,在没有机会关闭其连接或通道的情况下终止进程),则任何未确认的消息似乎永远不会被确认。

    我已经看到一些参考文献(例如这个问题),表示该频道在没有连接时会死亡,剩下的就是unack'd消息将被重新传递。这不是我看到的行为 - 相反,我得到了一个越​​来越多的标记IDLE的频道列表,以及越来越多的标记正在运行但没有活动的连接列表。

    是否需要一些配置注意一旦进程被杀死,连接就已经死了?

    编辑:
    我在VirtualBox中运行了rabbitmq服务器VM,显然无法通过NAT正确管理死入站连接。这对于直接在物理主机上运行的mq服务器来说效果很好。

    解决方案

    回答关闭。事实证明这不是一个真正的问题。

    我在VirtualBox VM中运行rabbitmq服务器,显然无法通过NAT正确管理死入站连接。这对于直接在物理主机上运行的mq服务器来说效果很好。

    http://www.it1352.com/987062.html






  • 相关阅读:
    SSH(Struts2+Spring+Hibernate)框架搭建流程<注解的方式创建Bean>
    hibernate用注解(annotation)配置sequence
    SSH(Struts2+Spring+Hibernate)框架搭建流程
    spring框架学习(一)
    struts2 s:if标签以及 #,%{},%{#}的使用方法
    js页面跳转参考代码大全
    Struts 2常用的Ajax标签
    Struts2文件上传(基于表单的文件上传)
    struts.custom.i18n.resources国际化
    Struts2常用标签
  • 原文地址:https://www.cnblogs.com/softidea/p/12275556.html
Copyright © 2011-2022 走看看