Victor Müller is wondering if it's possible to disable the embedding of the schema in Debezium CDC JSON messages to potentially reduce message size.
Victor Müller
Asked on Feb 14, 2024
Yes, it is possible to disable the embedding of the schema in Debezium CDC JSON messages. This can be achieved by configuring Debezium to use a different serialization format such as AVRO. By using AVRO, the schema is stored separately and not embedded in each message, potentially reducing the message size. Here is an example of how you can configure Debezium to use AVRO serialization:
Properties props = new Properties();
props.put("key.converter", "io.confluent.connect.avro.AvroConverter");
props.put("value.converter", "io.confluent.connect.avro.AvroConverter");
// Add any other necessary configurations