Hi,
  The attached zip file contains the implementation of a OpenJPA DataCache
plug-in for Coherence Distributed Caching Product. The plug-in honors the
'name' property value of @DataCache annotation in a persistent class X to
cache instances of X to a corresponding named partition in Coherence. The
plug-in
is activated by the following configuration in META-INF/persistence.xml

        <property name="openjpa.DataCacheManager" value="coherence"/>

  The ProductDerivation magic wires up other appropriate plug-ins. 

  To use it, add coherence-openjpa.jar to your classpath. 

   This plug-in is somewhat differs in spirit from its counterpart
TangosolCache (available in Kodo) in a sense that this one leaves *every*
configuration of the cache to Coherence including how changes are
communicated in a distributed environment i.e. OpenJPA effectively
relinquishes its responsibility to broadcast changes via
RemoteCommitProvider to other, possibly, remote L2 caches. This plug-in also
recognizes that the instances of different classes may be cached to
different Coherence partitions (Kodo version put all of them in one single
named partition).   

The source code is provided (without any warranty or copyright). Usage is
exemplified via JUnit Test cases and a simple persistence.xml configuration. 

   The build script requires to be edited for your local environment. 

   Good night & Good luck --

Pinaki
http://www.nabble.com/file/p16378911/coherence-openjpa.zip
coherence-openjpa.zip 


-- 
View this message in context: 
http://www.nabble.com/How-to-set-a-tangosol-cache-per-entity--tp16336199p16378911.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.

Reply via email to