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

Log WARN messages when WAL search runs without advancing

XMLWordPrintable

    • False
    • Hide

      None

      Show
      None
    • False

      Given the following use case:

      2025-02-20 00:12:30,667 INFO [cdc-debezium|task-0] Obtained valid replication slot ReplicationSlot [active=false, latestFlushedLsn=LSN{0/1619BB8}, catalogXmin=1122] (io.debezium.connector.postgresql.connection.PostgresConnection) [task-thread-cdc-debezium-0]
      2025-02-20 00:12:30,754 INFO [cdc-debezium|task-0] Found previous offset PostgresOffsetContext [sourceInfoSchema=Schema{io.debezium.connector.postgresql.Source:STRUCT}, sourceInfo=source_info[server='cdc-debezium'db='debezium', lsn=LSN{0/5E15FE8}, txId=33556, messageType=INSERT, lastCommitLsn=LSN{0/5E15FE8}, timestamp=2025-02-19T21:38:07.765805Z, snapshot=FALSE, schema=, table=], lastSnapshotRecord=false, lastCompletelyProcessedLsn=LSN{0/5E15FE8}, lastCommitLsn=LSN{0/5E15FE8}, streamingStoppingLsn=null, transactionContext=TransactionContext [currentTransactionId=null, perTableEventCount={}, totalEventCount=0], incrementalSnapshotContext=IncrementalSnapshotContext [windowOpened=false, chunkEndPosition=null, dataCollectionsToSnapshot=[], lastEventKeySent=null, maximumKey=null]] (io.debezium.connector.postgresql.PostgresConnectorTask) [task-thread-cdc-debezium-0]
      

      When the LSN values on the slot have a last flushed value that exceeds the offset details, the WAL search will run indefinitely.

      We should add a WARN message when the slot's latest flushed value is after the offset value, and we should additional log a WARN message when the WAL search isn't advancing after a specific number of seconds.

              Unassigned Unassigned
              ccranfor@redhat.com Chris Cranford
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: