Open lovegq opened 2 weeks ago
因为mysql 存在8小时自动杀死连接的问题,而seatunnel 组件提供的jdbc连接池选择是hikaricp,虽然快但是没有探活机制保证,一旦连接失败,任务就执行失败。
有sink_retry解决
有sink_retry解决
在哪里有说明? 请告知一下 谢谢
即便设置 sink 的max-retry 也会出现这个问题 Caused by: com.mysql.cj.exceptions.CJCommunicationsException: The last packet successfully received from the server was 20,539,370 milliseconds ago. The last packet sent successfully to the server was 20,539,379 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem. at jdk.internal.reflect.GeneratedConstructorAccessor36.newInstance(Unknown Source) ~[?:?] at jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:?] at java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499) ~[?:?] at java.lang.reflect.Constructor.newInstance(Constructor.java:480) ~[?:?] at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:62) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:105) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:150) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.exceptions.ExceptionFactory.createCommunicationsException(ExceptionFactory.java:166) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.protocol.a.NativeProtocol.send(NativeProtocol.java:629) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.protocol.a.NativeProtocol.sendCommand(NativeProtocol.java:684) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.protocol.a.NativeProtocol.sendCommand(NativeProtocol.java:156) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.NativeSession.queryServerVariable(NativeSession.java:589) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.jdbc.ConnectionImpl.isReadOnly(ConnectionImpl.java:1366) ~[mysql-connector-j-8.0.33.jar:8.0.33] ... 18 more Caused by: java.net.SocketException: Broken pipe at sun.nio.ch.NioSocketImpl.implWrite(NioSocketImpl.java:425) ~[?:?] at sun.nio.ch.NioSocketImpl.write(NioSocketImpl.java:445) ~[?:?] at sun.nio.ch.NioSocketImpl$2.write(NioSocketImpl.java:831) ~[?:?] at java.net.Socket$SocketOutputStream.write(Socket.java:1035) ~[?:?] at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:81) ~[?:?] at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:142) ~[?:?] at com.mysql.cj.protocol.a.SimplePacketSender.send(SimplePacketSender.java:55) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.protocol.a.TimeTrackingPacketSender.send(TimeTrackingPacketSender.java:50) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.protocol.a.NativeProtocol.send(NativeProtocol.java:620) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.protocol.a.NativeProtocol.sendCommand(NativeProtocol.java:684) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.protocol.a.NativeProtocol.sendCommand(NativeProtocol.java:156) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.NativeSession.queryServerVariable(NativeSession.java:589) ~[mysql-connector-j-8.0.33.jar:8.0.33] at com.mysql.cj.jdbc.ConnectionImpl.isReadOnly(ConnectionImpl.java:1366) ~[mysql-connector-j-8.0.33.jar:8.0.33] ... 18 more
mysql到mysql cdc,同样遇到此问题,设置autoReconnect=true
后也没有用,seatunel运行1~2天进程就会挂掉
CJCommunicationsException: The last packet successfully received from the server was 85,426,089 milliseconds ago. The last packet sent successfully to the server was 85,426,093 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem.
同样遇到了这个问题
add socketTimeout=30000 to jdbc url.
Search before asking
What happened
com.mysql.cj.exceptions.StatementIsClosedException: No operations allowed after statement closed.
SeaTunnel Version
2.3.8
SeaTunnel Config
Running Command
Error Exception
Zeta or Flink or Spark Version
No response
Java or Scala Version
No response
Screenshots
No response
Are you willing to submit PR?
Code of Conduct