gpt4 book ai didi

eclipse - 至少扫描了一个 JAR 以查找 TLD 但不包含 TLD

转载 作者:行者123 更新时间:2023-11-28 21:43:38 26 4
gpt4 key购买 nike

我一直在 tomcat 7.30 (eclipse juno) 上得到这个

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.

好吧,我去了 conf\logging.properties 并将所有 INFO 变为 FINE 并取消注释该行

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

而且我仍然看到 至少有一个 JAR 已针对 TLD 进行了扫描,但不包含 TLD。启用调试日志...

那么我应该怎么做才能看到那些 jar ?

日志位置:

tomcat 日志位于 $CATALINA_HOME\logs\catalina.yyyy-mm-dd.log 中。 Eclipse 将它们打印在控制台中——如果你想记录你的控制台 you must

In the servers tab, double-click on the Tomcat Server. You will get a screen called Overview. Click on "Open launch configuration". Click on the "Common" tab. Towards the bottom of the screen you can check the "File" checkbox and then specify a file that can be used to log your console (catalina.out) output. Finally, restart the Tomcat server.

最佳答案

如果想要conf\logging.properties 阅读one must (另请参见 here)将此文件转储到 Servers\Tomcat v7.0 Server at localhost-config\ 文件夹中,然后添加以下行:

-Djava.util.logging.config.file="${workspace_loc}\Servers\Tomcat v7.0 Server at localhost-config\logging.properties" -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager

launch configuration 的 VM 参数一个正在使用。

这可能需要重新启动或两次(或没有),但最后我在控制台中看到亮红色:

FINE: No TLD files were found in [file:/C:/Dropbox/eclipse_workspaces/javaEE/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/ted2012/WEB-INF/lib/logback-classic-1.0.7.jar]. Consider adding the JAR to the tomcat.util.scan.DefaultJarScanner.jarsToSkip or org.apache.catalina.startup.TldConfig.jarsToSkip property in CATALINA_BASE/conf/catalina.properties file. //etc

我仍然不知道这个 FINE 警告出现的确切时间 - 不会在 tomcat 启动时立即出现 编辑:来自评论@Stephan:“每次在 JSP 文件中进行任何更改时都会出现 FINE 警告”


奖励:要使警告消失,请添加 catalina.properties :

# Additional JARs (over and above the default JARs listed above) to skip when
# scanning for TLDs. The list must be a comma separated list of JAR file names.
org.apache.catalina.startup.TldConfig.jarsToSkip=logback-classic-1.0.7.jar,\
joda-time-2.1.jar,joda-time-2.1-javadoc.jar,mysql-connector-java-5.1.24-bin.jar,\
logback-core-1.0.7.jar,javax.servlet.jsp.jstl-api-1.2.1.jar

关于eclipse - 至少扫描了一个 JAR 以查找 TLD 但不包含 TLD,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12905001/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com