Commit 8baaa76
committed
GH-3163: Propagate EH error down to the
Fixes: #3163
The `MessagingMessageListenerAdapter` in its `asyncFailure()` calls the `handleException()`,
but uses the same input `Throwable` for the `super.asyncFailure()`.
This may not lead to expected state of the system, when an `AmqpRejectAndDontRequeueException`
might be expected as a trigger to DLQ the failed message.
* Fix `MessagingMessageListenerAdapter.asyncFailure()` to override error with an exception thrown
from the `handleException()` before calling `super.asyncFailure()`
**Auto-cherry-pick to `3.2.x`**super.asyncFailure
1 parent 7d633ae commit 8baaa76
File tree
2 files changed
+38
-8
lines changed- spring-rabbit/src
- main/java/org/springframework/amqp/rabbit/listener/adapter
- test/kotlin/org/springframework/amqp/rabbit/annotation
2 files changed
+38
-8
lines changedLines changed: 6 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
172 | 172 | | |
173 | 173 | | |
174 | 174 | | |
| 175 | + | |
| 176 | + | |
175 | 177 | | |
176 | 178 | | |
177 | | - | |
| 179 | + | |
178 | 180 | | |
179 | 181 | | |
180 | 182 | | |
181 | | - | |
| 183 | + | |
182 | 184 | | |
183 | | - | |
| 185 | + | |
| 186 | + | |
184 | 187 | | |
185 | 188 | | |
186 | 189 | | |
| |||
Lines changed: 32 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
26 | 27 | | |
27 | 28 | | |
| 29 | + | |
28 | 30 | | |
29 | 31 | | |
| 32 | + | |
30 | 33 | | |
31 | 34 | | |
32 | 35 | | |
| |||
56 | 59 | | |
57 | 60 | | |
58 | 61 | | |
59 | | - | |
| 62 | + | |
60 | 63 | | |
61 | 64 | | |
62 | 65 | | |
| |||
67 | 70 | | |
68 | 71 | | |
69 | 72 | | |
70 | | - | |
| 73 | + | |
71 | 74 | | |
72 | 75 | | |
73 | 76 | | |
| |||
83 | 86 | | |
84 | 87 | | |
85 | 88 | | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
86 | 94 | | |
87 | 95 | | |
88 | 96 | | |
| |||
114 | 122 | | |
115 | 123 | | |
116 | 124 | | |
117 | | - | |
118 | | - | |
119 | | - | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
120 | 144 | | |
121 | 145 | | |
122 | 146 | | |
| |||
132 | 156 | | |
133 | 157 | | |
134 | 158 | | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
135 | 162 | | |
136 | 163 | | |
137 | 164 | | |
| |||
0 commit comments