bunny-mock icon indicating copy to clipboard operation
bunny-mock copied to clipboard

implement basic dead letter exchange behaviour

Open aiomaster opened this issue 7 years ago • 4 comments

I tried to implement a basic handling of dead-letter-exchanges. If a message gets nacked or rejected it could be delivered in a dead letter exchange if specified in the arguments parameter of the queue options. See here for details: http://rubybunny.info/articles/extensions.html#dead_letter_exchange_dlx

I would be glad to get some feedback on this PR cause I don't know if this is a good idea and if the code is good enough.

aiomaster avatar Oct 25 '17 21:10 aiomaster

Coverage Status

Coverage remained the same at 100.0% when pulling 6729e0d6dce8cf42f28a2faa5a28d8b2145695f4 on webit-de:master into 468fe867815bd86fde9797379964b7336d5bcfec on arempe93:master.

coveralls avatar Oct 26 '17 09:10 coveralls

Coverage Status

Coverage remained the same at 100.0% when pulling b53c0fd04aca095b48fd2b49b01a21c5df2c79d5 on webit-de:master into 468fe867815bd86fde9797379964b7336d5bcfec on arempe93:master.

coveralls avatar Nov 07 '17 18:11 coveralls

hey @aiomaster - thanks for the PR! i'll try to take a look and merge it soon 👍

arempe93 avatar Nov 07 '17 18:11 arempe93

@arempe93 This would be great! I just tested it for direct exchanges with queues having a dead letter queue and the only way to get dead letters with bunny mock for now is by rejecting the message. It would need more effort to simulate a dead lettering because of message timeout. The last dead letter reason is a full queue, but this is also difficult with bunny-mock, cause you have to define what "full" means.

aiomaster avatar Nov 08 '17 08:11 aiomaster