解决 Failed to obtain JDBC Connection; nested exception is java.sql.SQLNonTransientConnectionExceptio

当出现这样的问题时,是数据库的连接的问题
Failed to obtain JDBC Connection; nested exception is java.sql.SQLNonTransientConnectionException: Public Key Retrieval is not allowed
解决 Failed to obtain JDBC Connection; nested exception is java.sql.SQLNonTransientConnectionExceptio_第1张图片

只需要在配置文件中的数据库连接的url加上一个 allowPublicKeyRetrieval=true
然后再重新启动项目就行了

你可能感兴趣的:(MySQL,java,sql,开发语言)