jdbctemplate.update,updatechecker.java_Mybatis中出現net.sf.ehcache.util.UpdateCheck

 2023-10-21 阅读 24 评论 0

摘要:問題描述jdbctemplate.update,最近每次啟動項目都會拋如下異常:2018-03-29 09:01:07,831 DEBUG [ehcache] net.sf.ehcache.util.UpdateChecker.checkForUpdate(UpdateChecker.java:107) - Update check failed:java.io.IOException: Server returned HTTP response co

問題描述

jdbctemplate.update,最近每次啟動項目都會拋如下異常:

2018-03-29 09:01:07,831 DEBUG [ehcache] net.sf.ehcache.util.UpdateChecker.checkForUpdate(UpdateChecker.java:107) - Update check failed:

java.io.IOException: Server returned HTTP response code: 403 for URL: http://www.terracotta.org/kit/reflector?pageID=update.properties&patch=UNKNOWN&tc-product=ehcache-core+2.9.0&tc-version=2.9.0&uptime-secs=1&kitID=ehcache.default&jvm-version=1.8.0_151&os-name=Mac+OS+X&id=-1062731415&source=ehcache-core&jvm-name=Java+HotSpot%28TM%29+64-Bit+Server+VM&platform=x86_64

at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1894) ~[?:1.8.0_151]

at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492) ~[?:1.8.0_151]

at net.sf.ehcache.util.UpdateChecker.getUpdateProperties(UpdateChecker.java:153) ~[ehcache-2.9.0.jar:2.9.0]

at net.sf.ehcache.util.UpdateChecker.doCheck(UpdateChecker.java:117) ~[ehcache-2.9.0.jar:2.9.0]

at net.sf.ehcache.util.UpdateChecker.checkForUpdate(UpdateChecker.java:104) [ehcache-2.9.0.jar:2.9.0]

at net.sf.ehcache.util.UpdateChecker.run(UpdateChecker.java:95) [ehcache-2.9.0.jar:2.9.0]

at java.util.TimerThread.mainLoop(Timer.java:555) [?:1.8.0_151]

at java.util.TimerThread.run(Timer.java:505) [?:1.8.0_151]

1

2

3

4

5

6

7

8

9

10

經研究發現,原來是ehcache搗的鬼,每次啟動都會訪問官方網站查看是否有最新版本,這樣也可以統計有多少用戶和服務器在使用ehcache。很可能是一個后門程序,默認開啟。

解決方案

找到ehcache.xml文件,ehcache標簽中添加屬性updateCheck=”false”,如下:1

或如下方式修改:1

2

再次重啟,問題即可解決。

40e6deb383a7fa26d8deb40f2a3ce14d.png

版权声明:本站所有资料均为网友推荐收集整理而来,仅供学习和研究交流使用。

原文链接:https://hbdhgg.com/2/157832.html

发表评论:

本站为非赢利网站,部分文章来源或改编自互联网及其他公众平台,主要目的在于分享信息,版权归原作者所有,内容仅供读者参考,如有侵权请联系我们删除!

Copyright © 2022 匯編語言學習筆記 Inc. 保留所有权利。

底部版权信息