[jboss-user] [Clustering/JBoss] - Re: Cannot persist replicated EntityBeans

bstansberry@jboss.com do-not-reply at jboss.com
Thu Mar 29 09:22:44 EDT 2007


Your conception of entity caching (and associated replication) is incorrect.  The purpose of the cache is to all the EntityManager to save database reads by letting it cache some data in memory.  Writing to (or even reading from) the database is not a part of an entity cache's intended behavior -- that is the job of the EntityManager.

You need to use a shared database.

Using a replicated cache just means that when the EntityManager on node2 checks its cache, its cache includes any updates made by the EntityManager on node1. Otherwise it could read stale data from the cache. But both EntityManagers need to be working with the same underlying database.


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4032758#4032758

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4032758



More information about the jboss-user mailing list