You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "Robin Moffatt (Jira)" <ji...@apache.org> on 2020/02/06 15:24:00 UTC

[jira] [Commented] (KAFKA-7052) ExtractField SMT throws NPE - needs clearer error message

    [ https://issues.apache.org/jira/browse/KAFKA-7052?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17031671#comment-17031671 ] 

Robin Moffatt commented on KAFKA-7052:
--------------------------------------

Thanks [~gunnar.morling], this put me on the correct tracks - in this particular case to get this to work I set 
{code:java}
"include.schema.changes": "false", {code}
 
----
 

In general though, wouldn't a more descriptive error (e.g. "{color:#de350b}_ExtractField : field 'id' not found in Key_{color}") be more useful to users? Why would this be more disruptive? It would certainly be easier for troubleshooting :)

> ExtractField SMT throws NPE - needs clearer error message
> ---------------------------------------------------------
>
>                 Key: KAFKA-7052
>                 URL: https://issues.apache.org/jira/browse/KAFKA-7052
>             Project: Kafka
>          Issue Type: Improvement
>          Components: KafkaConnect
>            Reporter: Robin Moffatt
>            Priority: Major
>
> With the following Single Message Transform: 
> {code:java}
> "transforms.ExtractId.type":"org.apache.kafka.connect.transforms.ExtractField$Key",
> "transforms.ExtractId.field":"id"{code}
> Kafka Connect errors with : 
> {code:java}
> java.lang.NullPointerException
> at org.apache.kafka.connect.transforms.ExtractField.apply(ExtractField.java:61)
> at org.apache.kafka.connect.runtime.TransformationChain.apply(TransformationChain.java:38){code}
> There should be a better error message here, identifying the reason for the NPE.
> Version: Confluent Platform 4.1.1



--
This message was sent by Atlassian Jira
(v8.3.4#803005)