hibernate and ehcache replication

Posted by cachingsol on Stack Overflow See other posts from Stack Overflow or by cachingsol
Published on 2010-02-19T01:05:34Z Indexed on 2010/03/19 0:11 UTC
Read the original article Hit count: 604

Filed under:
|
|

Hi, I am working on a cache replication solution between nodes

Node A - master node => Hibernate + Database + Ehcache as secondary cache
Node B - regional node=> Ehcache as prmiary cache. no Hibernate

Node B is used only as near-by cache for query.

Now I am updating data (Say SudentInfo) in Node A, it gets persisted and cached correctly. On replication side (I am using JMS) it sends a message to Node B. But the problem is, the message it sends is of instance CacheEntry(deep Inside Element), there is no way to resurrect the original object (StudentInfo). What I got in node B is CacheEntry with some attributes of Students but not actually an Student Object.

Please note that I don't need Hibernate session/persistence in Node B, node B is only for fast query, persistence is done through Node A. So has anybody tried any solution like this? Is there any way to convert CacheEntry to actual object? or Tell ehcache to replicate original object rather than CacheEntry.

Thanks for the help

© Stack Overflow or respective owner

Related posts about hibernate

Related posts about ehcache