今日份“一波两折”

今天的项目启动可谓是一波两折。

第一折在于——项目明明正常启动了,为什么无法访问接口?

我苦思无果,翻阅各路大神博客,他们的解决方法我一一尝试

端口号被占用:https://blog.51cto.com/longithome/2427188

防火墙的锅https://www.imooc.com/wenda/detail/439926

没加@ComponentScan注解https://www.it610.com/article/1293079722275708928.htm

非同级目录https://blog.csdn.net/weixin_39934868/article/details/89396273

最终,黄天不负苦心人,我成功的被自己蠢到了。

第二折在于——启动后,连接mysql报错:The server time zone value 'Öйú±ê׼ʱ¼ä' is unrecognized or represents more than one time zone.

参考大佬博客:https://blog.csdn.net/m0_37822490/article/details/100940070

将原本为这样的连接语句

jdbc:mysql://localhost:3306/db2020?useUnicode=true&characterEncoding=utf-8&useSSL=false

改为这样:

jdbc:mysql://localhost:3306/db2020?useUnicode=true&characterEncoding=utf-8&useSSL=false&serverTimezone=GMT%2B8

问题很快速的就解决了。

今日份填坑到此结束,下期再见~

猜你喜欢

转载自blog.csdn.net/YaraRen/article/details/111144951
今日推荐