1   package com.trendmicro.grid.acl.ds.cache;
2   
3   /**
4    * Defines cache constants that may be used for tweaking (via sys-properties).
5    *
6    * @author juergen_kellerer, 2011-03-25
7    * @version 1.0
8    */
9   public interface CacheSettings {
10  	//START-SNIPPET:CacheSettings
11  
12  	/**
13  	 * Toggles synchronous cache operations (disabled by default, use if timing issues occur).
14  	 */
15  	boolean IS_SYNCHRONOUS = Boolean.getBoolean("gacl.3rdcache.is.synchronous");
16  
17  	/**
18  	 * Toggles whether negative ('null') results are cached.
19  	 */
20  	boolean NO_NEGATIVE_CACHING = Boolean.getBoolean("gacl.3rdcache.no.negative.caching");
21  
22  	/**
23  	 * Toggles whether the batch interface is used for cache operations.
24  	 */
25  	boolean NO_BATCHING = Boolean.getBoolean("gacl.3rdcache.no.batching");
26  
27  	/**
28  	 * Enables the use of hard disk storage for caching (using JDBM btree format).
29  	 */
30  	boolean ENABLE_PERSISTENCE = Boolean.getBoolean("gacl.3rdcache.enable-persistence");
31  
32  	/**
33  	 * Toggles whether the 3rd level caching is disabled (temporarily).
34  	 * <p/>
35  	 * Note: Disabling the cache with this option does not remove the aspects.
36  	 * If caching must be disabled permanently to reduce resource usage, the
37  	 * file 'cache.jar' should be removed from the lib directory.
38  	 */
39  	boolean DISABLED = Boolean.getBoolean("gacl.3rdcache.disabled");
40  
41  	/**
42  	 * Names the 3rd level cache region that stores FileDetail instances.
43  	 */
44  	String CACHE_REGION_FILE_DETAILS = "3rdLevel.Cache.FileDetails";
45  	/**
46  	 * Names the 3rd level cache region that stores FileInformation instances.
47  	 */
48  	String CACHE_REGION_FILE_INFORMATION = "3rdLevel.Cache.FileInformation";
49  	/**
50  	 * Names the 3rd level cache region that stores PackageDetails instances.
51  	 */
52  	String CACHE_REGION_PACKAGE_DETAILS = "3rdLevel.Cache.PackageDetails";
53  	/**
54  	 * Names the 3rd level cache region that stores PackageInformation instances.
55  	 */
56  	String CACHE_REGION_PACKAGE_INFORMATION = "3rdLevel.Cache.PackageInformation";
57  	/**
58  	 * Names the 3rd level cache region that maps FileIdentifiers against their package names.
59  	 */
60  	String CACHE_REGION_PACKAGE_FILE_IDENTIFIERS = "Internal.3rdLevel.Cache.PackageFileIdentifiers";
61  	/**
62  	 * Names the 3rd level cache region that contains names that are known to be unknown (= negative result caching)
63  	 */
64  	String CACHE_REGION_UNKNOWN_NAMES = "Internal.3rdLevel.Cache.UnknownNames";
65  	/**
66  	 * Names the 3rd level cache region that contains identifiers that are known to be unknown (= negative result caching)
67  	 */
68  	String CACHE_REGION_UNKNOWN_FILE_IDENTIFIERS = "Internal.3rdLevel.Cache.UnknownFileIdentifiers";
69  
70  	//END-SNIPPET:CacheSettings
71  }