关于解决SpringMvc连接池——Mon Nov 09 23:34:24 CST 2020 WARN:SSL 错误

关于这个错误的解释百度上有一大堆,关于解决方法找了很久才看到了个情况和自己一样的也解决了。

首先情况是在写MVC配置运行后,一直都显示有这个错

Fri Mar 30 14:55:35 CST 2018 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification.

之前没有用mvc连接数据库的时候报这个错误直接在连接数据库地址后面加上useSSL=false就可以解决了

本来轻车熟路的我很熟练的在连接池后加上了useSSL=false,如下

 

 

 

可是这次并没有解决,而且出现了新的错误如下:

 

后来百度了一些发现需要转义,然后按照下面的写就对了。(试了这个就对了就发出来了,毕竟耽误了我好长时间)

  jdbc:mysql://127.0.0.1:3306/li?characterEncoding=utf8&useSSL=false"

 

 

 

 

 

 

 

原文路径:https://blog.csdn.net/huang_xin2016/article/details/79757799

posted on 2020-11-10 00:10  bigbig钊  阅读(519)  评论(0编辑  收藏  举报