|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.sandev.basics.util.IDCacheBase
org.sandev.basics.util.NamedSingletonIDCache
Provides singleton instances of one or more IDCaches. Instances are accessed by unique key. Using multiple caches allows multi-server deployments to run in a single VM without compromising the boundaries between server-specific or node-specific caches.
WARNING: Nodes sharing access to the same IDCache must have the
same security and authorization to avoid retrieving more or less
information than what should be there.
To share the same cache across multiple nodes with different
authorization, write a "privileged" node to hold the cache, and then
have all the client nodes get their info served from the privileged
node via Authorizers.
| Field Summary | |
protected static java.util.Hashtable |
caches
Map of cache instances |
| Fields inherited from class org.sandev.basics.util.IDCacheBase |
map, revisionCheck |
| Constructor Summary | |
protected |
NamedSingletonIDCache()
no access, default ctor. |
| Method Summary | |
static IDCache |
getSingletonIDCache(java.lang.String key)
return the correct singleton cache |
protected static IDCache |
instantiateCache(java.lang.String key)
Instantiate a cache. |
| Methods inherited from class org.sandev.basics.util.IDCacheBase |
checkRevisionNumber, clear, getInstance, getMap, idToKey, init, putInstance, removeInstance, setRevisionCheck |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.sandev.basics.util.IDCache |
clear, getInstance, getMap, putInstance, removeInstance |
| Field Detail |
protected static java.util.Hashtable caches
| Constructor Detail |
protected NamedSingletonIDCache()
| Method Detail |
public static IDCache getSingletonIDCache(java.lang.String key)
protected static IDCache instantiateCache(java.lang.String key)
Because of the thread lineup, the initial conditional test
is actually necessary.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||