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

RecordsStreamProducer forgets to convert commitTime from nanoseconds to microseconds

XMLWordPrintable

    • Hide

      1. Start a connector with initial snapshot.
      2. After the snapshot completes, do some manual updates in the monitored tables.
      3. The records from the snapshot have ts_usec in microseconds while the ones from the streaming have ts_usec in nanoseconds.

      Show
      1. Start a connector with initial snapshot. 2. After the snapshot completes, do some manual updates in the monitored tables. 3. The records from the snapshot have ts_usec in microseconds while the ones from the streaming have ts_usec in nanoseconds.

      RecordsStreamProducer forgets to convert `commitTime` from ReplicationMessage (which is in nanoseconds) to microseconds to match what is being used in the RecordsSnapshotProducer.

      As a result you get the following records with the ts_usec values being inconsistent.

      {"ts_usec":1551879833470000,"txId":105511269,"lsn":5938262159080,"schema":"public","table":
      "ims_item","snapshot":true,"last_snapshot_record":false}
      
      {"ts_usec":1551938559907450000,"txId":105513931,"lsn":5941569690428,"schema":"public","table":"ims_item","snapshot":false,"last_snapshot_record":null}
      

      The issue seems to affect all versions apparently.

              Unassigned Unassigned
              hashhar Ashhar Hasan (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: