Skip to content

[FLINK-37503] Compatibility Issue with MySQL Syntax SHOW MASTER STATUS #3955

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

wolfboys
Copy link
Member

[FLINK-37503] Compatibility Issue with MySQL Syntax SHOW MASTER STATUS

In newer versions of MySQL, the SHOW MASTER STATUS syntax has been deprecated and replaced with show binary log status. Since this syntax is used in MySQL CDC, compatibility adjustments are required.

@github-actions github-actions bot added docs Improvements or additions to documentation mysql-cdc-connector labels Mar 18, 2025
Copy link
Member

@yuxiqian yuxiqian left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for @wolfboys's nice work! Just left some minor comments.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MySQL 8.4+ support would be great, but validation is still required. Shall we parameterize MySQL UT & E2e test cases with multiple LTS versions (including 5.7, 8.0, 8.4), just like MongoDB CDC?

Comment on lines +140 to 141
Users can check Binlog_Ignore_DB and Binlog_Do_DB through the `show master status` or `` command

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or `` ? There seems to be a lack of concrete content.

@@ -62,6 +65,8 @@ public class DebeziumUtils {

private static final Logger LOG = LoggerFactory.getLogger(DebeziumUtils.class);

private static String showMasterStmt = null;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why use 'static String'?Is there a special situation for this use?

@joyCurry30
Copy link
Contributor

During the Source initialization, we've included a MySQL version check. Could we leverage this phase to determine which SQL syntax variant to use?
IntelliJ IDEA 2025-03-26 14 25 31

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to documentation mysql-cdc-connector
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants