0
15:31:58,339 TRACE Grizzly(1) org.hibernate.engine.jdbc.internal.JdbcResourceRegistryImpl:211 - Closing prepared statement [com.mysql.jdbc.JDBC4PreparedStatement@7bf4109: select producttyp0_.id as id5_, producttyp0_.name as name5_ from production_queue.Product_Type producttyp0_ where producttyp0_.name='Phone Case']
15:31:58,339 TRACE Grizzly(1) org.hibernate.engine.jdbc.internal.proxy.AbstractStatementProxyHandler:88 - Handling invocation of statement method [invalidate]
15:31:58,339 TRACE Grizzly(1) org.hibernate.engine.jdbc.internal.LogicalConnectionImpl:234 - Starting after statement execution processing [ON_CLOSE]
15:31:58,339 TRACE Grizzly(1) org.hibernate.engine.internal.StatefulPersistenceContext:1016 - Initializing non-lazy collections
15:31:58,339 TRACE Grizzly(1) org.hibernate.internal.SessionImpl:1383 - Setting cache mode to: NORMAL
15:31:58,339 TRACE Grizzly(1) org.hibernate.internal.SessionImpl:340 - Closing session
15:31:58,340 TRACE Grizzly(1) org.hibernate.engine.jdbc.internal.LogicalConnectionImpl:193 - Closing logical connection
15:31:58,340 TRACE Grizzly(1) org.hibernate.engine.jdbc.internal.proxy.ConnectionProxyHandler:110 - Handling invocation of connection method [close]
15:31:58,340 TRACE Grizzly(1) org.hibernate.engine.jdbc.internal.proxy.ConnectionProxyHandler:206 - Invalidating connection handle
15:31:58,340 TRACE Grizzly(1) org.hibernate.engine.jdbc.internal.JdbcResourceRegistryImpl:205 - Closing JDBC container [org.hibernate.engine.jdbc.internal.JdbcResourceRegistryImpl@4557b620]
15:31:58,340 DEBUG Grizzly(1) org.hibernate.engine.jdbc.internal.LogicalConnectionImpl:314 - Releasing JDBC connection
15:31:58,341 DEBUG Grizzly(1) org.hibernate.engine.jdbc.internal.LogicalConnectionImpl:332 - Released JDBC connection
15:31:58,341 DEBUG Grizzly(1) org.hibernate.engine.jdbc.internal.proxy.ConnectionProxyHandler:219 - HHH000163: Logical connection releasing its physical connection
15:31:58,341 TRACE Grizzly(1) org.hibernate.engine.jdbc.internal.LogicalConnectionImpl:207 - Logical connection closed
WARNING: Exception during FilterChain execution
WARNING: service exception

尽管进行了log4j.rootCategory=TRACE, stdout配置,但它似乎并不能帮助我获得有关此异常的更多详细信息。

log4j.properties

log4j.rootCategory=TRACE, stdout

log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%d{ABSOLUTE} %5p %t %c:%L - %m%n
4

1 回答 1

0

记录器看起来配置正确,但这并不意味着有问题的代码正确调用它。如果简单地调用记录器,因为LOG.warn(e)它只会记录异常消息,而不是完整的堆栈跟踪。

但是,仔细想想,日志中不存在时间戳和类文件是很奇怪的。您确定 Grizzly 使用 Log4J 并且没有通过 commons-logging 或 Java Util Logging 进行自己的日志记录吗?

于 2013-06-26T12:01:38.730 回答