DanielLeens commented on issue #10969: URL: https://github.com/apache/seatunnel/issues/10969#issuecomment-4569803825
Thanks for writing up the root cause so precisely. I checked the current SQL Server CDC path against your description, and this does look like a real bug rather than just a theoretical edge case. The key issue is the interval mismatch you pointed out: - the main change-event reading window treats the lower bound as inclusive; - but the DDL history query introduced in PR #10890 currently uses `ddl_lsn > ? AND ddl_lsn <= ?`. So if a schema-change event lands exactly on `fromLsn`, the row data can already be read under the new schema while the matching DDL event is skipped. That can indeed leave downstream consumers applying the wrong schema to the first rows in that window. The fix direction you proposed makes sense: the DDL history window should align with the closed-interval semantics of the main reader, and the regression test should explicitly cover the boundary case where `ddl_lsn == fromLsn`. Since you already marked that you are willing to submit a PR and the issue is assigned to you, please feel free to send the patch when ready. A focused test around the equal-boundary case will be especially important here. -- 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]
