At least one JAR was scanned for TLDs yet contained no TLDs

Tomcat 8.x

1. conf/logging.properties 修改:

# To see debug messages in TldLocationsCache, uncomment the following line:
org.apache.jasper.compiler.TldLocationsCache.level = FINE

2. 重啓Tomcat,啓動成功後,打開日誌文件catalina.out,看到很多行如下的日誌:

No TLD files were found in.....xxx.jar

3. 把所有2中出現的jar加到排除掃描的列表中,打開catalina.properties, 添加進去:
	tomcat.util.scan.StandardJarScanFilter.jarsToSkip=\
Linux下可使用如下命令把相關的Jar導出到一個文件中:

egrep "No TLD files were found in \[file:[^\]+\]" catalina.out -o | egrep "[^]/]+.jar" -o | sort | uniq | sed -e 's/.jar/.jar,\\/g' > skips.txt


4.  重啓Tomat,可看到之前的提示消息已經沒有了,重新註釋掉步驟1中的代碼,完成修改。
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章