https://bz.apache.org/bugzilla/show_bug.cgi?id=62945
Bug ID: 62945
Summary: JarScanFilter with tldSkip in context.xml still
produce INFO msg. if one jar is scanned due to another
reason
Product: Tomcat 9
Version: 9.0.13
Hardware: PC
Status: NEW
Severity: minor
Priority: P2
Component: Catalina
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: -----
I wanted to get rid of this message (and skip unneeded tld scans) that appears
at each war deployment:
23-Nov-2018 13:07:34.485 INFO [main]
org.apache.jasper.servlet.TldScanner.scanJars At least one JAR was scanned for
TLDs yet contained no TLDs. Enable debug logging for this logger for a complete
list of JARs that were scanned but no TLDs were found in them. Skipping
unneeded JARs during scanning can improve startup time and JSP compilation
time.
When I enabled FINE logging via
org.apache.jasper.compiler.TldLocationsCache.level = FINE
org.apache.jasper.servlet.TldScanner.level = FINE
it listed many jars that were scanned for TLDs but had none.
So according to
http://tomcat.apache.org/tomcat-8.0-doc/config/jar-scan-filter.html I added in
META-INF/context.xml this:
<Context>
<JarScanner>
<!--<JarScanFilter
tldSkip="${tomcat.util.scan.StandardJarScanFilter.jarsToSkip},myjar1.jar,myjar2.jar..."/>-->
<JarScanFilter tldSkip="*"/>
</JarScanner>
</Context>
This only partially worked. One jar file was still listed as scanned for TLDs
yet it has none:
23-Nov-2018 13:07:34.483 FINE [main]
org.apache.jasper.servlet.TldScanner$TldScannerCallback.scan No TLD files were
found in
[file:/D:/Tomcats/apache-tomcat-9.0.13/webapps/myWar/WEB-INF/lib/log4j-web.jar].
Consider adding the JAR to the
tomcat.util.scan.StandardJarScanFilter.jarsToSkip property in
CATALINA_BASE/conf/catalina.properties file.
This seems to be a bug. That jar is indeed scanned because it needs to be
scanned for something else (it has a log4j-web.jar\META-INF\web-fragment.xml).
In WEB-INF/web.xml of the .war I do have this (although this is probably not
relevant)
<absolute-ordering>
(...)
<name>log4j</name>
(...)
</absolute-ordering>
So it is a bug that it still gives that info/warning message after I added the
JarScanFilter right?
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]