Ehcache 2.10.5 | Product Documentation | Ehcache Operations Guide | Logging | SLFJ Logging
 
SLFJ Logging
As of 1.7.1, Ehcache uses the slf4j logging facade, so you can plug in your own logging framework. The following information pertains to Ehcache logging. For information about SLF4J in general, refer to the SLF4J website.
With SLF4J, users must choose a concrete logging implementation at deploy time. The options include Maven and the download kit.
Concrete Logging Implementation use in Maven
The maven dependency declarations are reproduced here for convenience. Add one of these to your Maven POM.
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-jdk14</artifactId>
<version>1.5.8</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>1.5.8</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>1.5.8</version>
</dependency>
Concrete Logging Implementation use in the Download Kit
The slf4j-api jar is in the kit along with the Ehcache jars so that, if the app does not already use SLF4J, you have everything you need. Additional concrete logging implementations can be downloaded from SLF4J website.

Copyright © 2010-2018 | Software AG, Darmstadt, Germany and/or Software AG USA, Inc., Reston, VA, USA, and/or its subsidiaries and/or its affiliates and/or their licensors.
Innovation Release