Commit 02213b4
GH-2050: Configure ErrHandlDeser if no delegate
Fixes #2050
The application can have several consumer factories when one fully relies
on the configuration properties for its deserializers and other
configures them programmatically.
The consumer factory now calls `configure()` on the `Deserializer`
independently of its origins.
See #1879
In this case the `ErrorHandlingDeserializer` consults
`spring.deserializer.key.delegate.class` or `spring.deserializer.value.delegate.class`
for its delegate overriding provided explicitly programmatically
* Fix `ErrorHandlingDeserializer` to check it `delegate` and `failedDeserializationFunction`
for null before taking their values from the respective configuration properties
* Add `spring.deserializer.value.delegate.class` property to `testJsonSerDeIgnoreTypeHeadersInbound()`
configuration to ensure that it does not override an explicit `JsonDeserializer` delegate
* Fix warning in the `EmbeddedKafkaBroker` about `this.` prefix for a `static logger` property1 parent 146c491 commit 02213b4
File tree
3 files changed
+9
-4
lines changed- spring-kafka-test/src/main/java/org/springframework/kafka/test
- spring-kafka/src
- main/java/org/springframework/kafka/support/serializer
- test/java/org/springframework/kafka/listener
3 files changed
+9
-4
lines changedLines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
595 | 595 | | |
596 | 596 | | |
597 | 597 | | |
598 | | - | |
| 598 | + | |
599 | 599 | | |
600 | 600 | | |
601 | 601 | | |
| |||
Lines changed: 6 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
132 | 132 | | |
133 | 133 | | |
134 | 134 | | |
135 | | - | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
136 | 138 | | |
137 | 139 | | |
138 | 140 | | |
139 | | - | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
140 | 144 | | |
141 | 145 | | |
142 | 146 | | |
| |||
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2257 | 2257 | | |
2258 | 2258 | | |
2259 | 2259 | | |
2260 | | - | |
| 2260 | + | |
| 2261 | + | |
2261 | 2262 | | |
2262 | 2263 | | |
2263 | 2264 | | |
| |||
0 commit comments