org.apache.kafka.connect.errors.DataException: Avro union types containing null are only supported as optional fields and should have exactly two entries.

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

Do you know how to solve this issue? Write a tip to help other users and build your expert profile.

Solutions on the web

via GitHub by zako
, 1 year ago
Avro union types containing null are only supported as optional fields and should have exactly two entries.
via Google Groups by Unmesh Joshi, 4 months ago
Avro union types containing null are only supported as optional fields and should have exactly two entries.
org.apache.kafka.connect.errors.DataException: Avro union types containing null are only supported as optional fields and should have exactly two entries.
at io.confluent.connect.avro.AvroData.toConnectSchema(AvroData.java:1135)
at io.confluent.connect.avro.AvroData.toConnectSchema(AvroData.java:1105)
at io.confluent.connect.avro.AvroData.toConnectSchema(AvroData.java:1017)
at io.confluent.connect.avro.AvroData.toConnectData(AvroData.java:781)

Users with the same issue

You are the first who have seen this exception. Write a tip to help other users and build your expert profile.

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.