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

mysql-binlog-connector doesn't support new binlog events added with MySQL 5.7

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Critical Critical
    • 0.4
    • 0.3.6
    • mysql-connector
    • None

      After testing DBZ-0.3.6 we have found more issues with MySQL-5.7.

      Here is stacktrace we got :

      [2016-12-23 11:52:51,833] ERROR Task patient-data-connector_trunk-10-0 threw an uncaught and unrecoverable exception (org.apache.kafka.connect.runtime.WorkerTask:142)
      org.apache.kafka.connect.errors.ConnectException: Unknown event type 38
      at io.debezium.connector.mysql.AbstractReader.wrap(AbstractReader.java:164)
      at io.debezium.connector.mysql.AbstractReader.failed(AbstractReader.java:131)
      at io.debezium.connector.mysql.BinlogReader$ReaderThreadLifecycleListener.onEventDeserializationFailure(BinlogReader.java:655)
      Caused by: java.io.IOException: Unknown event type 38
      at com.github.shyiko.mysql.binlog.event.deserialization.EventHeaderV4Deserializer.getEventType(EventHeaderV4Deserializer.java:45)
      at com.github.shyiko.mysql.binlog.event.deserialization.EventHeaderV4Deserializer.deserialize(EventHeaderV4Deserializer.java:35)
      

      After some digging we found that mysql-binlog-connector (shipped with DBZ-0.3.6) supports all 36 event types according to official specs : https://dev.mysql.com/doc/internals/en/binlog-event-type.html

      However, MySQL-5.7 source code indeed includes 38 event types : https://github.com/mysql/mysql-server/blob/71f48ab393bce80a59e5a2e498cd1f46f6b43f9a/libbinlogevents/include/binlog_event.h#L328

      VIEW_CHANGE_EVENT= 37,
      /* Prepared XA transaction terminal event similar to Xid */
        XA_PREPARE_LOG_EVENT= 38,
      

      Looks like MySQL folks haven't updated official docs after made enhancements.

      Add please 37 and 38 event types to mysql-binlog-connector library

              rhauch Randall Hauch (Inactive)
              anton_nazaruk Anton Nazaruk (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: