This content has been marked as final. Show 1 reply
We have a JBossCache based impl that is clustered across multiple Web Services Containers.
The requirement is to have CacheLoader used only when multiple CacheLoaders in a cluster access the same underlying store which is a Oracle Database
SharedStoreCacheLoader seems to be the best bet as it does not do redundant reads and writes are done only from the coordinator.
This class has not been tested extensively. Why not use a regular CacheLoader, e.g. JDBCCacheLoader, and set CacheLoaderShared=true ? This way, reads are local, and writes are performed as write-through ops on the CacheLoader by the node that does the write.
Can somebody help me on this? We currently are using the JDBCCacheLoader but it is too expensive as it keeps reading from the database
What do you mean ? JDBCCacheLoader reads the first time, the keeps the value in the cache.
There is also a situation that is as follows:
We have a tree that goes as /XXXX/a/b/c (one region)
and another that goes /XXXX/x/y/z (another region)
I want to persist and read only the /XXXX/a/b/c and not the /XXXX/x/y/z region
Today I do not see that it is possible using the JDBCCacheLoader. Is this correct? Also are regions supported for this kind of classloading? Primarily we want one section of the tree to be persisted while another region to not be persisted towards requirements and perf needs
No, this is not supported, but on the roadmap (far away though): http://jira.jboss.com/jira/browse/JBCACHE-64.
For now, use 2 instances of the cache