Ehcache 2.10.6 | Product Documentation | Ehcache Developer Guide | Class Loading | Loading of ehcache.xml Resources
 
Loading of ehcache.xml Resources
If the configuration is otherwise unspecified, Ehcache looks for a configuration in the following order:
*Thread.currentThread().getContextClassLoader().getResource("/ehcache.xml")
*ConfigurationFactory.class.getResource("/ehcache.xml")
*ConfigurationFactory.class.getResource("/ehcache-failsafe.xml")
Ehcache uses the first configuration found. Note the use of "/ehcache.xml", which requires that ehcache.xml be placed at the root of the classpath (i.e., not in any package).

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.