Logging configuration in Hibernate

To provide logging, Hibernate uses SLF4J (http://www.slf4j.org) as the logging framework. SLF4J does not provide a logging alternative to Log4j, the Java logging API, or to any other. Instead, it is an API that sits on top of these other APIs to provide you with a common logging API to use in the source code. It forwards all logging events to either a logging framework, such as Log4j, the Java logging API, JCL, or so on. For each supported logging framework, SLF4J provides a JAR file, called SLF4J Binding, that must be in the application classpath when that framework is used as the underlying logging framework. For instance, SLF4J provides slf4j-log4j12.jar for Log4j that must be in the classpath when SLF4J is ...

Get Spring Persistence with Hibernate now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.