Caused by: java.sql.SQLException: com.mysql.cj.jdbc.Driver
解决方法:我直接去掉pom.xml 文件下 mysql驱动类的版本号,让他自动下载哪个就是哪个。
org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘dataSource’ defined in class path resource [com/alibaba/druid/spring/boot/autoconfigure/DruidDataSourceAutoConfigure.class]: Invocation of init method failed; nested exception is java.sql.SQLException: Access denied for user ‘***’@‘localhost’ (using password: YES)
解决方法:我用的是腾讯云的云服务器,登录云服务器之后发现mysql 没有开,执行 systemctl start mysql 开启mysq