Commit c4fdca4
committed
Provide queue name and reason to publisher for rejected messages
## What?
1. This commit adds the name of the queue that rejected a message as well
as the reason why the message was rejected in the Rejected outcome for AMQP 1.0.
2. For MQTT 5.0 publishers, the reason is provided in the PUBACK packet.
## Why?
It may be helpful for publishers to know which queue out of multilple
target queues rejected the message. One such use case is described in
#1443
It may also be helpful to know for publishers whether the given target
queue rejected the message because its maximum queue length was reached
or because the target queue happens to be unavailable.
## How?
RabbitMQ will include the UTF-8 encoded queue name (rather than an AMQP
address) as well as the reason in the `info` field of the Rejected outcome's `error` field:
* `queue: <queue name>`
* `reason: maxlen | unavailable`
For MQTT 5.0, if the queue length limit is exceeded, RabbitMQ will
return the reason code for `Quota exceeded` to the publisher.1 parent 8911fa6 commit c4fdca4
File tree
11 files changed
+229
-124
lines changed- deps
- rabbitmq_mqtt
- src
- test
- rabbitmq_shovel/src
- rabbit
- src
- test
- release-notes
11 files changed
+229
-124
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
373 | 373 | | |
374 | 374 | | |
375 | 375 | | |
376 | | - | |
| 376 | + | |
| 377 | + | |
| 378 | + | |
| 379 | + | |
377 | 380 | | |
378 | 381 | | |
379 | 382 | | |
| |||
692 | 695 | | |
693 | 696 | | |
694 | 697 | | |
695 | | - | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
696 | 709 | | |
697 | 710 | | |
698 | 711 | | |
| |||
716 | 729 | | |
717 | 730 | | |
718 | 731 | | |
719 | | - | |
| 732 | + | |
720 | 733 | | |
721 | 734 | | |
722 | 735 | | |
723 | 736 | | |
724 | 737 | | |
725 | | - | |
| 738 | + | |
726 | 739 | | |
727 | 740 | | |
728 | 741 | | |
729 | 742 | | |
730 | 743 | | |
731 | 744 | | |
732 | 745 | | |
733 | | - | |
734 | | - | |
| 746 | + | |
| 747 | + | |
| 748 | + | |
| 749 | + | |
| 750 | + | |
| 751 | + | |
| 752 | + | |
| 753 | + | |
735 | 754 | | |
736 | 755 | | |
737 | 756 | | |
| |||
745 | 764 | | |
746 | 765 | | |
747 | 766 | | |
748 | | - | |
| 767 | + | |
749 | 768 | | |
750 | 769 | | |
751 | 770 | | |
| |||
2116 | 2135 | | |
2117 | 2136 | | |
2118 | 2137 | | |
2119 | | - | |
| 2138 | + | |
2120 | 2139 | | |
2121 | 2140 | | |
2122 | 2141 | | |
| |||
2584 | 2603 | | |
2585 | 2604 | | |
2586 | 2605 | | |
| 2606 | + | |
| 2607 | + | |
| 2608 | + | |
| 2609 | + | |
| 2610 | + | |
2587 | 2611 | | |
2588 | 2612 | | |
2589 | 2613 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2787 | 2787 | | |
2788 | 2788 | | |
2789 | 2789 | | |
2790 | | - | |
| 2790 | + | |
2791 | 2791 | | |
2792 | 2792 | | |
2793 | 2793 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
390 | 390 | | |
391 | 391 | | |
392 | 392 | | |
393 | | - | |
| 393 | + | |
394 | 394 | | |
395 | 395 | | |
396 | 396 | | |
| |||
405 | 405 | | |
406 | 406 | | |
407 | 407 | | |
408 | | - | |
409 | | - | |
410 | | - | |
411 | | - | |
412 | | - | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
413 | 421 | | |
414 | 422 | | |
415 | 423 | | |
| |||
425 | 433 | | |
426 | 434 | | |
427 | 435 | | |
428 | | - | |
| 436 | + | |
429 | 437 | | |
430 | 438 | | |
431 | 439 | | |
432 | 440 | | |
433 | 441 | | |
434 | | - | |
435 | | - | |
436 | | - | |
437 | | - | |
438 | | - | |
439 | 442 | | |
440 | 443 | | |
441 | 444 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
232 | 232 | | |
233 | 233 | | |
234 | 234 | | |
235 | | - | |
| 235 | + | |
| 236 | + | |
236 | 237 | | |
237 | 238 | | |
238 | 239 | | |
| |||
253 | 254 | | |
254 | 255 | | |
255 | 256 | | |
256 | | - | |
| 257 | + | |
257 | 258 | | |
258 | 259 | | |
259 | 260 | | |
| |||
291 | 292 | | |
292 | 293 | | |
293 | 294 | | |
294 | | - | |
295 | | - | |
| 295 | + | |
| 296 | + | |
296 | 297 | | |
297 | 298 | | |
298 | 299 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
| 84 | + | |
84 | 85 | | |
85 | 86 | | |
86 | 87 | | |
| |||
101 | 102 | | |
102 | 103 | | |
103 | 104 | | |
| 105 | + | |
104 | 106 | | |
105 | 107 | | |
106 | 108 | | |
| |||
158 | 160 | | |
159 | 161 | | |
160 | 162 | | |
| 163 | + | |
161 | 164 | | |
162 | 165 | | |
163 | 166 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1125 | 1125 | | |
1126 | 1126 | | |
1127 | 1127 | | |
1128 | | - | |
| 1128 | + | |
1129 | 1129 | | |
1130 | 1130 | | |
1131 | 1131 | | |
| |||
0 commit comments