The Store Manager's configuration file must contain two properties:
no.feide.moria.store.cachestoreconf
Should give the full path to the configuration file for JBossCache. The format of this file is defined in the JBossCache documentation. The eviction policy configuration must be contained in this file. An example (partial) configuration is
<Attribute name="EvictionPolicyClass"> no.feide.moria.store.TicketTTLEvictionPolicy </Attribute> <Attribute name="EvictionPolicyConfig"> <Config> <Attribute name="wakeUpIntervalSeconds">60</Attribute> <Attribute name="maxNodes">200000</Attribute> <Region name="Login Ticket"> <Attribute name="timeToLive">375</Attribute> </Region> <Region name="Service Ticket"> <Attribute name="timeToLive">375</Attribute> </Region> <Region name="Single Sign-On Ticket"> <Attribute name="timeToLive">36000</Attribute> </Region> <Region name="Ticket Granting Ticket"> <Attribute name="timeToLive">4500</Attribute> </Region> <Region name="Proxy Ticket"> <Attribute name="timeToLive">750</Attribute> </Region> </Config> </Attribute>
Each regions' name match the actual name of the branch in the cache. The time to live is the time in seconds. The wakeUpIntervalSeconds attribute defines how often the thread doing the evictions should be run. The maxNodes attributes is required by the underlying API but isn't really used in this policy.
no.feide.moria.store.real_ttl_percentage
The percentage defining the actual ticket time to live. This is used to calculate the actual validity time of tickets. While the time defined in the eviction policy declaration defines the time the tickets will remain in the cache, the time the tickets are valid is a sub one multiple of this. For example, Service Tickets may be configured to stay in the cache for m seconds, but is considered valid for use only n percent of this period if the time to live percentage is set to n. Thus, the real TTL = mn/100.
Example Store Manager configuration file: