e-mhui opened a new pull request, #4291:
URL: https://github.com/apache/flink-cdc/pull/4291

   ## What is the purpose of the change
   
   Sync Debezium PR #7004 (DBZ-9428) to add REPLACE INTO to DML statement 
filtering in `handleQueryEvent`.
   
   Before this fix, `REPLACE INTO` statements generated by 
**pt-table-checksum** (which sets session-level `binlog_format=STATEMENT`) were 
not filtered and incorrectly passed to DDL parsing, causing connector failure.
   
   ## Brief change log
   
   - Add `DML_REPLACE_PREFIX` constant and extract `isDmlStatement()` method
   - Change `equals()` to `startsWith()` for more robust DML prefix detection
   - Update `Strings.getBegin` length from 7 to 8 to accommodate `"REPLACE "` 
(8 chars)
   - Use parameterized logging `'{}'` instead of string concatenation
   - Add integration test `testDmlStatementFilteringWithStatementBinlogFormat` 
simulating pt-table-checksum scenario using `SET SESSION binlog_format = 
'STATEMENT'`
   
   ## Verifying this change
   
   This change added a test:
   - `BinlogSplitReaderTest#testDmlStatementFilteringWithStatementBinlogFormat` 
— uses NOGTID container with session-level `binlog_format=STATEMENT` to 
simulate pt-table-checksum, verifying REPLACE INTO/INSERT/UPDATE/DELETE as 
QueryEvents are properly filtered without crashing the connector.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to