[
https://issues.apache.org/jira/browse/KAFKA-17994?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17898369#comment-17898369
]
Matthias J. Sax edited comment on KAFKA-17994 at 11/14/24 6:48 PM:
-------------------------------------------------------------------
Ah. Thanks for clarification. That's helpful.
I agree that we should fix this... As it's a regression, I'll mark is as
blocker for 3.9.1 and 4.0.0.
Current work-around for 3.9.0 would be adding `try-catch` and re-throw as
`RuntimeException`.
was (Author: mjsax):
Ah. Thanks for clarification. That's helpful.
I agree that we should fix this... As it's a regression, I'll mark is as
blocker for 3.9.1 and 4.0.0
> Runtime exceptions are not handled when deserializing kafka stream record
> -------------------------------------------------------------------------
>
> Key: KAFKA-17994
> URL: https://issues.apache.org/jira/browse/KAFKA-17994
> Project: Kafka
> Issue Type: Bug
> Components: streams
> Affects Versions: 3.9.0
> Reporter: Ilya
> Assignee: Matthias J. Sax
> Priority: Blocker
> Fix For: 4.0.0, 3.9.1
>
>
> When we got a PR to upgrade kafka clients 3.8.1 -> 3.9.0, we saw some failing
> tests. They were relating to using a DeserializationExceptionHandler with
> 'log and continue' strategy, however on newest version the stream was just
> crashing when Jackson was trying to deserialize a faulty json and this
> handler was not invoked.
> In this
> [KIP-1033|https://cwiki.apache.org/confluence/display/KAFKA/KIP-1033%3A+Add+Kafka+Streams+exception+handler+for+exceptions+occurring+during+processing],
> specifically in this PR
> [https://github.com/apache/kafka/pull/16745/files#diff-77791b213bb41d1df63a23860f1faf4394dfbd7d6c4ed9cd021950d82c31c24f]
> a change was introduced to catch only RuntimeException type and handle them
> in the handler. However, all the Jackson exceptions inherit Exception type,
> not RuntimeException -
> https://fasterxml.github.io/jackson-core/javadoc/2.14/com/fasterxml/jackson/core/JacksonException.html
> So with this change all the Jackson exceptions (or any checked exceptions)
> would not be passed to the DeserializationExceptionHandler like it was before.
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)