If you have a 4-node J2EE application server cluster, say all running instances of a hibernate application. How does caching work in this situation? Does this work any good? Should it be stopped only?
It seems that the data on a particular node will quickly become stale because the database data changes by changing the other nodes to another database, in such a situation, how to ever hibernate But can it be believed that its cash is up to date? First, there are 2 caches in hibernate, the first level is the cache, which can not be removed, and It is called a hibernate session. After that, there is a second level cache which is optional and pluggable (eg eauca). It works in many requests and, most probably, this is the cache that you are referring to.
If you work on a package environment, then you need a second level cache which is the cluster members. It can do that, caching is a difficult topic and you need a deep understanding to use it without starting other problems. Caching is a bit more difficult in a package environment.
Comments
Post a Comment