User development,
A new message was posted in the thread "How to manage empty data with a
CacheLoader?":
http://community.jboss.org/message/524184#524184
Author : Manik Surtani
Profile :
http://community.jboss.org/people/manik.surtani@jboss.com
Message:
--------------------------------------------------------------
This is a common problem with cache stores. If stuff isn't in memory there is every
chance it is stored elsewhere and this must be checked.
Optimising the cache store will help to some degree, but if most of your threads result in
cache misses, then you should rethink why you use a cache store (or even a cache!) in the
first place.
Starting with optimisation, the JDBC cache store is one of the slowest, due to remote
network connections and all sorts of bottlenecks in databases, combined with the fact that
most databases need to be tuned extensively to start performing. One recommendation is to
consider other forms of cache storage. BDBJE is a good engine, fast and powerful.
If you have to live with a JDBC backend, I recommend taking a look at Infinispan's
JDBC cache store - a complete rewrite from the JBoss Cache one, and with some interesting
optimisations in place that will help perform better. Note that Infinispan's JDBC
cache store is not compatible with JBoss Cache, but you could enhance JBoss Cache's
implementation using similar techniques.
But both of the above techniques just improve the performance of the cache store and not
really solve your problem. Regarding your solution of using a "dummy entry",
this does make sense provided you have a known and finite set of keys. But if you know
this set of keys and it is finite, then why do you use a cache store, since if it is to
deal with persisting evicted objects, then you would still always have to check the store
for existence of the object.
Cheers
Manik
--------------------------------------------------------------
To reply to this message visit the message page:
http://community.jboss.org/message/524184#524184