root/trunk/calendar3/calCore/resources/properties/ehcache.xml

Revision 238 (checked in by douglm, 7 years ago)

Enable caching again - cache names now have a region prefix
Fixes so that quickstart hsql schema and dumprestore work ok

Line 
1 <ehcache>
2
3     <!-- Sets the path to the directory where cache .data files are created.
4
5          If the path is a Java System Property it is replaced by
6          its value in the running VM.
7
8          The following properties are translated:
9          user.home - User's home directory
10          user.dir - User's current working directory
11          java.io.tmpdir - Default temp file path -->
12     <diskStore path="java.io.tmpdir"/>
13
14
15     <!--Default Cache configuration. These will applied to caches programmatically created through
16         the CacheManager.
17
18         The following attributes are required for defaultCache:
19
20         maxInMemory       - Sets the maximum number of objects that will be created in memory
21         eternal           - Sets whether elements are eternal. If eternal,  timeouts are ignored and the element
22                             is never expired.
23         timeToIdleSeconds - Sets the time to idle for an element before it expires. Is only used
24                             if the element is not eternal. Idle time is now - last accessed time
25         timeToLiveSeconds - Sets the time to live for an element before it expires. Is only used
26                             if the element is not eternal. TTL is now - creation time
27         overflowToDisk    - Sets whether elements can overflow to disk when the in-memory cache
28                             has reached the maxInMemory limit.
29
30         -->
31     <defaultCache
32         maxElementsInMemory="10000"
33         eternal="false"
34         timeToIdleSeconds="120"
35         timeToLiveSeconds="120"
36         overflowToDisk="true"
37         />
38
39     <!--Predefined caches.  Add your cache configuration settings here.
40         If you do not have a configuration for your cache a WARNING will be issued when the
41         CacheManager starts
42
43         The following attributes are required for defaultCache:
44
45         name              - Sets the name of the cache. This is used to identify the cache. It must be unique.
46         maxInMemory       - Sets the maximum number of objects that will be created in memory
47         eternal           - Sets whether elements are eternal. If eternal,  timeouts are ignored and the element
48                             is never expired.
49         timeToIdleSeconds - Sets the time to idle for an element before it expires. Is only used
50                             if the element is not eternal. Idle time is now - last accessed time
51         timeToLiveSeconds - Sets the time to live for an element before it expires. Is only used
52                             if the element is not eternal. TTL is now - creation time
53         overflowToDisk    - Sets whether elements can overflow to disk when the in-memory cache
54                             has reached the maxInMemory limit.
55
56         -->
57
58     <!-- Calendar cache - these change infrequently and we should be able to cache all entries
59          in use
60         -->
61     <cache name="calendardb.org.bedework.calfacade.BwCalendar"
62         maxElementsInMemory="10000"
63         eternal="false"
64         timeToIdleSeconds="300"
65         timeToLiveSeconds="600"
66         overflowToDisk="true"
67         />
68
69     <cache name="calendardb.org.bedework.calfacade.BwCalendar.children"
70         maxElementsInMemory="10000"
71         eternal="false"
72         timeToIdleSeconds="300"
73         timeToLiveSeconds="600"
74         overflowToDisk="true"
75         />
76
77     <!-- categories cache - these change infrequently
78         -->
79     <cache name="calendardb.org.bedework.calfacade.BwCategory"
80         maxElementsInMemory="10000"
81         eternal="false"
82         timeToIdleSeconds="300"
83         timeToLiveSeconds="600"
84         overflowToDisk="true"
85         />
86
87     <!-- event.categories cache - these change infrequently
88         -->
89     <cache name="calendardb.org.bedework.calfacade.BwEventObj.categories"
90         maxElementsInMemory="10000"
91         eternal="false"
92         timeToIdleSeconds="300"
93         timeToLiveSeconds="600"
94         overflowToDisk="true"
95         />
96
97     <!-- locations cache - these change infrequently
98         -->
99     <cache name="calendardb.org.bedework.calfacade.BwLocation"
100         maxElementsInMemory="10000"
101         eternal="false"
102         timeToIdleSeconds="300"
103         timeToLiveSeconds="600"
104         overflowToDisk="true"
105         />
106
107     <!-- sponsors cache - these change infrequently
108         -->
109     <cache name="calendardb.org.bedework.calfacade.BwSponsor"
110         maxElementsInMemory="10000"
111         eternal="false"
112         timeToIdleSeconds="300"
113         timeToLiveSeconds="600"
114         overflowToDisk="true"
115         />
116
117     <!-- preferences cache - these change infrequently and we should be able to cache all entries
118          in use
119         -->
120     <cache name="calendardb.org.bedework.calfacade.svc.BwPreferences"
121         maxElementsInMemory="10000"
122         eternal="false"
123         timeToIdleSeconds="300"
124         timeToLiveSeconds="600"
125         overflowToDisk="true"
126         />
127
128     <cache name="calendardb.org.bedework.calfacade.svc.BwPreferences.subscriptions"
129         maxElementsInMemory="10000"
130         eternal="false"
131         timeToIdleSeconds="300"
132         timeToLiveSeconds="600"
133         overflowToDisk="true"
134         />
135
136     <cache name="calendardb.org.bedework.calfacade.svc.BwPreferences.views"
137         maxElementsInMemory="10000"
138         eternal="false"
139         timeToIdleSeconds="300"
140         timeToLiveSeconds="600"
141         overflowToDisk="true"
142         />
143
144     <!-- Subscription cache - these change infrequently and we should be able to cache all entries
145          in use
146         -->
147     <cache name="calendardb.org.bedework.calfacade.svc.BwSubscription"
148         maxElementsInMemory="10000"
149         eternal="false"
150         timeToIdleSeconds="300"
151         timeToLiveSeconds="600"
152         overflowToDisk="true"
153         />
154
155     <!-- users cache - these change infrequently but are referenced frequently, usually many
156          times a query.
157         -->
158
159     <cache name="calendardb.org.bedework.calfacade.BwUser"
160         maxElementsInMemory="10000"
161         eternal="false"
162         timeToIdleSeconds="300"
163         timeToLiveSeconds="600"
164         overflowToDisk="true"
165         />
166
167     <!-- Sample cache named sampleCache2
168         This cache contains 1000 elements. Elements will always be held in memory.
169         They are not expired. -->
170     <cache name="sampleCache2"
171         maxElementsInMemory="1000"
172         eternal="true"
173         timeToIdleSeconds="0"
174         timeToLiveSeconds="0"
175         overflowToDisk="false"
176         />
177
178     <!-- Place configuration for your caches following -->
179
180 </ehcache>
Note: See TracBrowser for help on using the browser.