-
Bug
-
Resolution: Obsolete
-
Major
-
None
-
1.6.0.Final, 1.6.1.Final
-
None
-
False
-
False
-
Undefined
-
- Use Debezium Server 1.6.0+
- Add debezium.source.database.allowPublicKeyRetrieval=true to the config file in /debezium/conf/application.properties
-
We encountered a problem when upgrading Debezium Server from 1.5.3 to 1.6.0 using MySQL connector.
We use debezium-server in an OpenShift cloud, putting the debezium configuration in /debezium/conf/application.properties
When using the property debezium.source.database.allowPublicKeyRetrieval=true, the property gets cast to lowercase, as seen in the startup log as the following line:
2021-08-03 09:20:08,249 INFO [io.deb.con.com.BaseSourceTask] (pool-3-thread-1) database.allowpublickeyretrieval = true
As this property for the MySQL connection is case sensitive (and for us mandatory), debezium cannot establish a connection to our database, producing the following error:
io.debezium.DebeziumException: java.sql.SQLNonTransientConnectionException: Public Key Retrieval is not allowed at io.debezium.connector.mysql.MySqlConnectorTask.start(MySqlConnectorTask.java:82) at io.debezium.connector.common.BaseSourceTask.start(BaseSourceTask.java:130) at io.debezium.embedded.EmbeddedEngine.run(EmbeddedEngine.java:759) at io.debezium.embedded.ConvertingEngineBuilder$2.run(ConvertingEngineBuilder.java:188) at io.debezium.server.DebeziumServer.lambda$start$1(DebeziumServer.java:142) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:829) Caused by: java.sql.SQLNonTransientConnectionException: Public Key Retrieval is not allowed at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:110) at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122) 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.setAutoCommit(JdbcConnection.java:383) at io.debezium.connector.mysql.MySqlConnectorTask.start(MySqlConnectorTask.java:79) ... 7 more Caused by: com.mysql.cj.exceptions.UnableToConnectException: Public Key Retrieval is not allowed at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490) at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:61) at com.mysql.cj.exceptions.ExceptionFactory.createException(ExceptionFactory.java:85) at com.mysql.cj.protocol.a.authentication.CachingSha2PasswordPlugin.nextAuthenticationStep(CachingSha2PasswordPlugin.java:128) at com.mysql.cj.protocol.a.authentication.CachingSha2PasswordPlugin.nextAuthenticationStep(CachingSha2PasswordPlugin.java:49) at com.mysql.cj.protocol.a.NativeAuthenticationProvider.proceedHandshakeWithPluggableAuthentication(NativeAuthenticationProvider.java:441) at com.mysql.cj.protocol.a.NativeAuthenticationProvider.connect(NativeAuthenticationProvider.java:174) at com.mysql.cj.protocol.a.NativeProtocol.connect(NativeProtocol.java:1350) at com.mysql.cj.NativeSession.connect(NativeSession.java:157) at com.mysql.cj.jdbc.ConnectionImpl.connectOneTryOnly(ConnectionImpl.java:953) at com.mysql.cj.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:823) ... 16 more
- relates to
-
DBZ-3760 Debezium snapshot.select.statement.overrides overrides not used
- Closed