We've found that our application is not useable (according to our customers) 
without entity caching enabled.

Like I emailed previously, we've made extensive improvements on the entity 
cache to increase the hit rate (only store value once if fetched by pkey and 
then in an entity condition) and lower memory consumption, store objects in 
dictionary, so that singleton for each Object fetched from db, String.intern() 
some Field values to make "PARTY".equals(..) checks faster, etc....  All these 
changes are required for multi-tenant systems where the is a rather high degree 
of redundant information in each tenant instance. (think of enumerations, 
types, etc...)

Copy on write database objects, so developer doesn't need to worry about 
corrupting other users of the data if they want/need to modify an entity.

Transactional support for the cache. (bug vs design choice in my opinion).

We've turned on entity caching by "default", and would like to remove the 
useCache from the api.  Don't mind returning a non-caching delegator via a 
delegator decorator, that way, there is no API difference.

The "don't need to cache" issue is handled by adding a WeakReference cache 
instance on top of SoftReference.  This makes it so that as long as the JVM has 
it in memory, why not re-use it?

I prefer to let the framework take care caching (and for how long, etc...) for 
me.

Marc

Reply via email to