Avoid Tombstone Event in Debezium - Kafka

2.3k Views Asked by At

Im using Confluent Kafka and Debezium Postgres Connector in Confluent Control Center to CDC to a Kafka Topic. I see that on delete event Debezium creates two records in the topic.

  1. One with Key and Value as null
  2. Second with "before" state filled in

I would like to avoid Debezium from writing the First record with Key filled and value as null .

I tried setting following property in the Connector :

tombstones.on.delete=false

But this doesnt seen to have any effect.

1

There are 1 best solutions below

1
On

I have the same settings but I run kafka connect in local.

I solved it by using ‘ TombstoneHandler’: https://docs.confluent.io/platform/current/connect/transforms/tombstonehandler.html