gpt4 book ai didi

RabbitMQ 确认超时

转载 作者:行者123 更新时间:2023-12-03 22:55:27 25 4
gpt4 key购买 nike

我正在使用 RPC 模式通过 RabbitMQ 处理我的对象。
您怀疑,我有一个对象,我希望该过程完成,然后将 ack 发送到 RPC 客户端。
默认确认有大约 3 分钟的超时。
我的过程需要很长时间。
如何更改每个对象的 ack 超时,或者我必须为处理这些类似进程做些什么?

最佳答案

RabbitMQ 的现代版本有一个 delivery acknowledgement timeout :

In modern RabbitMQ versions, a timeout is enforced on consumerdelivery acknowledgement. This helps detect buggy (stuck) consumersthat never acknowledge deliveries. Such consumers can affect node's ondisk data compaction and potentially drive nodes out of disk space.

If a consumer does not ack its delivery for more than the timeoutvalue (15 minutes by default), its channel will be closed with aPRECONDITION_FAILED channel exception. The error will be logged by thenode that the consumer was connected to.


错误信息为: Channel error on connection <####> : operation none caused a channel exception precondition_failed: consumer ack timed out on channel 1默认超时为 15 分钟(900000 毫秒),由 consumer_timeout 配置 rabbitmq.conf 中的参数

关于RabbitMQ 确认超时,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/53374144/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com