Uploaded image for project: 'Debezium'
  1. Debezium
  2. DBZ-8282

Log the record key when debezium fails to send the record to Kafka

XMLWordPrintable

      Bug report

      For bug reports, provide this information, please:

      Not a bug but it would be extremely useful to log the record key when Debezium fails to send a record to Kafka. It just logs the destination topic.

      What Debezium connector do you use and what version?

      I use Debezium Server 2.5.1.Final but the log is the same on all versions.

      What is the connector configuration?

      <Your answer>

      What is the captured database version and mode of deployment?

      (E.g. on-premises, with a specific cloud provider, etc.)

      I use PG but it's not related to the DB here.

      What behavior do you expect?

      I want Debezium to log the record key when it fails to send the record to Kafka. It just logs the topic.

      What behavior do you see?

      Debezium just logs the topic.

      Do you see the same behaviour using the latest released Debezium version?

      (Ideally, also verify with latest Alpha/Beta/CR version)

      Yes

      Do you have the connector logs, ideally from start till finish?

      (You might be asked later to provide DEBUG/TRACE level log)

      <Your answer>

      How to reproduce the issue using our tutorial deployment?

      There's no issue.

      Feature request or enhancement

      For feature requests or enhancements, provide this information, please:

      Which use case/requirement will be addressed by the proposed feature?

      I want to add the record key next to the destination topic to the ERROR log when debezium fails to send record to Kafka.

      In my case, debezium failed to send a record to Kafka because it was too big (bigger than the max.messagee.bytes property of the Kafka topic). The only way to unblock Debezium was to skip this record, but I had no way to identify the big record. I just knew which topic it was going to. So I forked the KafkaChangeConsumer and enriched the ERROR log with the record key. Then I was able to filter it out using provided Filter SMT.

      Implementation ideas (optional)

      I can do the PR to enrich the ERROR log.

      I had to duplicate my own custom version of the KafkaChangeConsumer class, but I'm sure it would be a good improvement.

       

            Unassigned Unassigned
            moussm Moustapha Mahfoud
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: