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中的代码,完成修改。

你可能感兴趣的:(J2EE)