| 1 |
<?xml version="1.0" encoding="UTF-8"?> |
| 2 |
|
| 3 |
<ehcache xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 4 |
xsi:noNamespaceSchemaLocation="../../main/config/ehcache.xsd"> |
| 5 |
|
| 6 |
<!-- Disable for test ehcache.xml. Should go to the same place. --> |
| 7 |
<diskStore path="java.io.tmpdir"/> |
| 8 |
|
| 9 |
<cacheManagerPeerProviderFactory class="net.sf.ehcache.distribution.RMICacheManagerPeerProviderFactory" |
| 10 |
properties="peerDiscovery=automatic, multicastGroupAddress=230.0.0.1, multicastGroupPort=4446, timeToLive=0"/> |
| 11 |
|
| 12 |
|
| 13 |
<cacheManagerPeerListenerFactory class="net.sf.ehcache.distribution.RMICacheManagerPeerListenerFactory" |
| 14 |
properties="hostName=, port=, socketTimeoutMillis="/> |
| 15 |
|
| 16 |
|
| 17 |
<defaultCache |
| 18 |
maxElementsInMemory="10" |
| 19 |
eternal="false" |
| 20 |
timeToIdleSeconds="5" |
| 21 |
timeToLiveSeconds="10" |
| 22 |
overflowToDisk="true" |
| 23 |
/> |
| 24 |
|
| 25 |
|
| 26 |
<!-- Sample cache named sampleCache1 --> |
| 27 |
<cache name="sampleCache1" |
| 28 |
maxElementsInMemory="10000" |
| 29 |
maxElementsOnDisk="1000" |
| 30 |
eternal="false" |
| 31 |
timeToIdleSeconds="360" |
| 32 |
timeToLiveSeconds="1000" |
| 33 |
overflowToDisk="true" |
| 34 |
memoryStoreEvictionPolicy="LRU"> |
| 35 |
<cacheEventListenerFactory class="net.sf.ehcache.event.NullCacheEventListenerFactory"/> |
| 36 |
</cache> |
| 37 |
|
| 38 |
<!-- Sample cache named sampleCache2. Is eternal. Is diskPersistent but does not overflow to disk --> |
| 39 |
<cache name="sampleCache2" |
| 40 |
maxElementsInMemory="1000" |
| 41 |
eternal="true" |
| 42 |
overflowToDisk="false" |
| 43 |
diskPersistent="true" |
| 44 |
/> |
| 45 |
|
| 46 |
<!-- Sample cache with a loader timeout --> |
| 47 |
<cache name="sampleCacheTimeout" |
| 48 |
maxElementsInMemory="10000" |
| 49 |
maxElementsOnDisk="1000" |
| 50 |
eternal="false" |
| 51 |
timeToIdleSeconds="360" |
| 52 |
timeToLiveSeconds="1000" |
| 53 |
overflowToDisk="true" |
| 54 |
cacheLoaderTimeoutMillis="1000" |
| 55 |
memoryStoreEvictionPolicy="LRU"> |
| 56 |
<cacheEventListenerFactory class="net.sf.ehcache.event.NullCacheEventListenerFactory"/> |
| 57 |
</cache> |
| 58 |
|
| 59 |
<!-- Sample cache named sampleCacheNoIdle, which does not specify the optional idle time --> |
| 60 |
<cache name="sampleCacheNoIdle" |
| 61 |
maxElementsInMemory="1000" |
| 62 |
eternal="false" |
| 63 |
timeToLiveSeconds="5" |
| 64 |
overflowToDisk="false" |
| 65 |
/> |
| 66 |
|
| 67 |
<!-- Sample cache named sampleCacheNotEternalButNoIdleOrExpiry --> |
| 68 |
<cache name="sampleCacheNotEternalButNoIdleOrExpiry" |
| 69 |
maxElementsInMemory="1000" |
| 70 |
eternal="false" |
| 71 |
overflowToDisk="false" |
| 72 |
/> |
| 73 |
|
| 74 |
<!-- A cache with short idle and live expiries, suitable for tests --> |
| 75 |
<cache name="sampleIdlingExpiringCache" |
| 76 |
maxElementsInMemory="1" |
| 77 |
eternal="false" |
| 78 |
timeToIdleSeconds="2" |
| 79 |
timeToLiveSeconds="5" |
| 80 |
overflowToDisk="true" |
| 81 |
diskPersistent="true" |
| 82 |
/> |
| 83 |
|
| 84 |
<!-- A cache which overflows to disk. The disk store is persistent |
| 85 |
between cache and VM restarts. The disk expiry thread interval is set to 10 minutes, overriding |
| 86 |
the default of 2 minutes. --> |
| 87 |
<cache name="persistentLongExpiryIntervalCache" |
| 88 |
maxElementsInMemory="500" |
| 89 |
eternal="false" |
| 90 |
timeToIdleSeconds="300" |
| 91 |
timeToLiveSeconds="600" |
| 92 |
overflowToDisk="true" |
| 93 |
diskPersistent="true" |
| 94 |
diskExpiryThreadIntervalSeconds="600" |
| 95 |
memoryStoreEvictionPolicy="LRU" |
| 96 |
/> |
| 97 |
|
| 98 |
<!-- Page Caches for Web filter tests --> |
| 99 |
<cache name="CachedLogin" |
| 100 |
maxElementsInMemory="10" |
| 101 |
eternal="false" |
| 102 |
timeToIdleSeconds="10000" |
| 103 |
timeToLiveSeconds="10000" |
| 104 |
overflowToDisk="true"> |
| 105 |
</cache> |
| 106 |
|
| 107 |
|
| 108 |
<cache name="FooterPageCache" |
| 109 |
maxElementsInMemory="10" |
| 110 |
eternal="false" |
| 111 |
timeToIdleSeconds="10000" |
| 112 |
timeToLiveSeconds="10000" |
| 113 |
overflowToDisk="true"> |
| 114 |
</cache> |
| 115 |
|
| 116 |
|
| 117 |
<!-- Test Page Caches --> |
| 118 |
<cache name="SimplePageCachingFilter" |
| 119 |
maxElementsInMemory="10" |
| 120 |
eternal="false" |
| 121 |
timeToIdleSeconds="10000" |
| 122 |
timeToLiveSeconds="10000" |
| 123 |
overflowToDisk="true" |
| 124 |
diskPersistent="true" |
| 125 |
clearOnFlush="false" > |
| 126 |
</cache> |
| 127 |
|
| 128 |
<cache name="SimplePageFragmentCachingFilter" |
| 129 |
maxElementsInMemory="10" |
| 130 |
eternal="false" |
| 131 |
timeToIdleSeconds="10000" |
| 132 |
timeToLiveSeconds="10000" |
| 133 |
diskPersistent="true" |
| 134 |
overflowToDisk="true"> |
| 135 |
</cache> |
| 136 |
|
| 137 |
|
| 138 |
<cache name="Simple/PageCachingFilterWithBlankPage#Problem" |
| 139 |
maxElementsInMemory="10" |
| 140 |
eternal="false" |
| 141 |
timeToIdleSeconds="10000" |
| 142 |
timeToLiveSeconds="10000" |
| 143 |
overflowToDisk="true"> |
| 144 |
</cache> |
| 145 |
|
| 146 |
<!-- Asynchronous Caching tests --> |
| 147 |
<cache name="net.sf.ehcache.constructs.asynchronous.MessageCache" |
| 148 |
maxElementsInMemory="1" |
| 149 |
eternal="false" |
| 150 |
timeToIdleSeconds="10000" |
| 151 |
timeToLiveSeconds="10000" |
| 152 |
overflowToDisk="true"> |
| 153 |
<cacheEventListenerFactory class="net.sf.ehcache.distribution.RMICacheReplicatorFactory" |
| 154 |
properties="replicateAsynchronously=true, |
| 155 |
replicatePuts=true, |
| 156 |
replicateUpdates=true, |
| 157 |
replicateUpdatesViaCopy=true, |
| 158 |
replicateRemovals=true "/> |
| 159 |
</cache> |
| 160 |
|
| 161 |
<cache name="exceptionHandlingCache" |
| 162 |
maxElementsInMemory="10000" |
| 163 |
maxElementsOnDisk="1000" |
| 164 |
eternal="false" |
| 165 |
timeToIdleSeconds="360" |
| 166 |
timeToLiveSeconds="1000" |
| 167 |
overflowToDisk="true" |
| 168 |
memoryStoreEvictionPolicy="LRU"> |
| 169 |
<cacheEventListenerFactory class="net.sf.ehcache.event.NullCacheEventListenerFactory"/> |
| 170 |
<cacheLoaderFactory class="net.sf.ehcache.loader.CountingCacheLoaderFactory" |
| 171 |
properties="type=int,startCounter=10"/> |
| 172 |
<cacheExceptionHandlerFactory class="net.sf.ehcache.exceptionhandler.CountingExceptionHandlerFactory" |
| 173 |
properties="logLevel=FINE"/> |
| 174 |
</cache> |
| 175 |
|
| 176 |
<cache name="disabledStats" |
| 177 |
maxElementsInMemory="10" |
| 178 |
eternal="false" |
| 179 |
timeToIdleSeconds="5" |
| 180 |
timeToLiveSeconds="10" |
| 181 |
overflowToDisk="true" |
| 182 |
statistics="false"> |
| 183 |
</cache> |
| 184 |
|
| 185 |
</ehcache> |