Open raipragyaa opened 1 year ago
Can someone look into it?
From the configs pasted above, I can see two de-serializers configured. GlueSchemaRegistryKafkaDeserializer
inside consumer config file and AWSKafkaAvroDeserializer
is being used on the CLI. We recommend using only one of them. As long as the Kafka console consumer tool invokes the configure
method, the GlueSchemaRegistryDeserializationFacade
should get initialized.
@raipragyaa Do you have any updates on this?
@blacktooth It would be great if the documentation could include a deserialization example for Kafka Connect.
Could you possibly provide an example (consumer.properties)? Thanks!
I think the issue is here. Key is configured as schemas enable as false. I.e. key is not serialized to avro. But when deserializing in the consumer its specified as avro.. That wont work.
If you serializing key as int/string etc, use the int/string deserializer appropriately.
If you want to enable avro serialization make sure set the schemas enable to true. Looks like you are already using the schema naming generation class, that probably does some convention like
"key.converter" = "com.amazonaws.services.schemaregistry.kafkaconnect.AWSKafkaAvroConverter"
"key.converter.schemas.enable" = false
I have built a kafka pipeline using MSK, MSK Connect, Debezium Postgres Source connector and AWS Glue schema registry. On producer side, I am able to publish AVRO records with schemas in Glue schema registry, I am using aws glue schema registry library for integration between Kafka connect and glue schema registry. Below is my connector configurations for glue -
On consumer side, I have an EC2 instance. I am using
kafka-avro-console-consumer
command provided by confluent to read the message from AVRO topic. I have also added aws glue schema registry library JAR inconfluent/share/java/kafka-serde-tools
folder to make it available for the command. I am using following command -And the consumer config file contains -
I am expecting the command to print the messages for me but I get following error -
Looks like the GlueSchemaRegistryDeserializationFacade class isn't being initialised. So that the records are not able to deserialise. Is there a way to fix this issue and read AVRO records when using glue schema registry?