关闭tomcat时出现了下面警告:appears to have started a thread named [mysql-cj-abandoned-connection-cleanup] but has failed to stop it. This is very likely to create a memory leak. 具体信息如下:
原因是在spring的配置文件里,引用了一个未使用的连接,在关闭tomcat时,无法close这个连接,所以就会有内在泄露的风险,就有了这个警告。把没用的那个引用注释掉就正常了。如下:
关闭tomcat时,出现内存泄露警告
最新推荐文章于 2022-05-27 19:20:37 发布