Skip to content
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

[mysql->doris] debezium中连接 mysql8服务端报 #203

Closed
baisui1981 opened this issue Mar 29, 2023 · 0 comments
Closed

[mysql->doris] debezium中连接 mysql8服务端报 #203

baisui1981 opened this issue Mar 29, 2023 · 0 comments
Labels
bug Something isn't working
Milestone

Comments

@baisui1981
Copy link
Member

baisui1981 commented Mar 29, 2023

debezium中连接 mysql8服务端报
#184 解决了一半,在使用mysql8 时候会报如下错误

具体测试办法,使用MySQL 8作为服务端,客户端使用Flink-CDC mysql source8 的版本去连接

Caused by: com.mysql.cj.jdbc.exceptions.CommunicationsException: Communications link failure
org.apache.flink.table.api.TableException: Unexpected error while connecting to MySQL and validating
at com.ververica.cdc.connectors.mysql.MySqlValidator.validate(MySqlValidator.java:77) ~[?:?]
        at com.ververica.cdc.debezium.DebeziumSourceFunction.open(DebeziumSourceFunction.java:215) ~[?:?]
        at org.apache.flink.api.common.functions.util.FunctionUtils.openFunction(FunctionUtils.java:34) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.streaming.api.operators.AbstractUdfStreamOperator.open(AbstractUdfStreamOperator.java:102) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.streaming.runtime.tasks.OperatorChain.initializeStateAndOpenOperators(OperatorChain.java:437) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.streaming.runtime.tasks.StreamTask.restoreGates(StreamTask.java:582) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.streaming.runtime.tasks.StreamTaskActionExecutor$SynchronizedStreamTaskActionExecutor.call(StreamTaskActionExecutor.java:100) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.streaming.runtime.tasks.StreamTask.executeRestore(StreamTask.java:562) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.streaming.runtime.tasks.StreamTask.runWithCleanUpOnFail(StreamTask.java:647) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.streaming.runtime.tasks.StreamTask.restore(StreamTask.java:537) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.runtime.taskmanager.Task.doRun(Task.java:759) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at org.apache.flink.runtime.taskmanager.Task.run(Task.java:566) ~[flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]
        at java.lang.Thread.run(Thread.java:748) ~[?:1.8.0_251]
Caused by: com.mysql.cj.jdbc.exceptions.CommunicationsException: Communications link failure


The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
        at com.mysql.cj.jdbc.exceptions.SQLError.createCommunicationsException(SQLError.java:174) ~[?:?]
        at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:64) ~[?:?]
        at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:833) ~[?:?]
        at com.mysql.cj.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:453) ~[?:?]
        at com.mysql.cj.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:246) ~[?:?]
        at com.mysql.cj.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:198) ~[?:?]
        at io.debezium.jdbc.JdbcConnection.lambda$patternBasedFactory$1(JdbcConnection.java:231) ~[?:?]
        at io.debezium.jdbc.JdbcConnection.connection(JdbcConnection.java:872) ~[?:?]
        at io.debezium.connector.mysql.MySqlConnection.connection(MySqlConnection.java:79) ~[?:?]
        at io.debezium.jdbc.JdbcConnection.connection(JdbcConnection.java:867) ~[?:?]
        at io.debezium.jdbc.JdbcConnection.queryAndMap(JdbcConnection.java:638) ~[?:?]
        at io.debezium.jdbc.JdbcConnection.queryAndMap(JdbcConnection.java:512) ~[?:?]
        at com.ververica.cdc.connectors.mysql.MySqlValidator.checkVersion(MySqlValidator.java:93) ~[?:?]
        at com.ververica.cdc.connectors.mysql.MySqlValidator.validate(MySqlValidator.java:73) ~[?:?]
        ... 12 more

create table DDL

CREATE TABLE `bmp_log` (
  `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'ID',
  `menu` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT '菜单',
  `opt` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT '操作',
  `uri` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT '资源路径',
  `crt_time` datetime DEFAULT NULL COMMENT '操作时间',
  `crt_user` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT '操作人ID',
  `crt_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT '操作人',
  `crt_host` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci DEFAULT NULL COMMENT '操作主机',
  `body` text CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci COMMENT '请求参数',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=232356 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci;
@baisui1981 baisui1981 added bug Something isn't working 3.8.0 labels Mar 29, 2023
@baisui1981 baisui1981 added this to the v3.8.0 milestone Apr 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant