Looking at the code in OptimisticTreeCache it appears that Hibernate tells JBossCache to use an entity's version column for the cache's optimistic check if it has one.
However, if the entity doesn't have a version column it appears JBossCache doesn't do a version check of any kind when updating the cache. (Last update wins)
So, theoretically if I am using OptimisticeTreeCache with a Hibernate entity that don't contain a version column will my cache and DB remain synchronized? Is there any possible concurrent modification scenario where the 2 could become out of sync? I don't care if concurrent changes step on each other as long as the cache and the db remain synchronized.
Mike
|