79669246

Date: 2025-06-17 14:19:49
Score: 3.5
Natty:
Report link

We are using amqplib in a TypeScript/Node.js application to publish messages to RabbitMQ using sendToQueue, and although it returns true and we’ve wrapped it with ConfirmChannel and await channel.waitForConfirms(), we are experiencing a recurring issue where some messages are not delivered to the consumer. For instance, when 5 messages are sent, only 3 may be received by the consumer, even though no errors are thrown and waitForConfirms() resolves successfully. All queues are asserted with { durable: true }, messages are sent with { persistent: true }, and consumers are set up with noAck: false and are explicitly calling ack(msg). We’ve also tested with a Dead Letter Queue and found no messages routed there, suggesting they’re not being rejected or expired. The problem is intermittent and occurs under both light and moderate loads. We are trying to understand if this could be due to internal buffering, prefetch settings, missing acks, or a known edge case in amqplib where messages are silently dropped despite using confirmations. We would appreciate any insight into what could be causing this message loss, and whether there's an established approach or configuration that guarantees delivery reliability in this scenario.

Reasons:
  • Blacklisted phrase (1): what could be
  • Blacklisted phrase (1.5): would appreciate
  • Long answer (-1):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: BooToo