Currently, when writeToCacheAsynchronously is set to true, there are no mechanisms in place to ensure consistency: a read happening after a (async) write can return the state as it was before the write.
Also, writeToCacheAsynchronously is used at the CacheManager level and will apply no matter which cache implementation (memory/disk/both) is used.
It would be best to have:
- synchronous memory cache
- asynchronous disk cache
- consistency
Currently, when
writeToCacheAsynchronouslyis set to true, there are no mechanisms in place to ensure consistency: a read happening after a (async) write can return the state as it was before the write.Also,
writeToCacheAsynchronouslyis used at theCacheManagerlevel and will apply no matter which cache implementation (memory/disk/both) is used.It would be best to have: