BigMemory 4.3.9 | Product Documentation | BigMemory Max Configuration Guide | Defining a Distributed Configuration | About Distributed Configurations
 
About Distributed Configurations
The BigMemory Max configuration file (ehcache.xml by default) contains the configuration for one instance of a CacheManager (the Ehcache class managing a set of defined caches). This configuration file must be in your application's classpath to be found. When using a WAR file, ehcache.xml should be copied to WEB-INF/classes.
Note the following about ehcache.xml in a Terracotta cluster:
*The copy on disk is loaded into memory from the first Terracotta client (also called application server or node) to join the cluster.
*Once loaded, the configuration is persisted in memory by the Terracotta servers in the cluster and survives client restarts.
*In-memory configuration can be edited in the Terracotta Management Console (TMC). Changes take effect immediately but are not written to the original on-disk copy of ehcache.xml.
*The in-memory cache configuration is removed with server restarts if the servers are not in persistent mode (<restartable enabled="false">), which is the default. The original (on-disk) ehcache.xml is loaded.
*The in-memory cache configuration survives server restarts if the servers are in persistent mode (<restartable enabled="true">). If you are using the Terracotta servers with persistence of shared data, and you want the cluster to load the original (on-disk) ehcache.xml, the servers' database must be wiped by removing the data files from the servers' server-data directory. This directory is specified in the Terracotta configuration file in effect (tc-config.xml by default). Wiping the database causes all persisted shared data to be lost.
A minimal distributed-cache configuration should have the following configured:
*A CacheManager. See Configuring a CacheManager.
*A Clustering element in individual cache configurations. See terracotta.
*A source for Terracotta client configuration. See terracottaConfig.