Hi,
I'd like to test data cache by simply enable for read-only objects, however,
it seems to be slower than cacheless.
1) Can someone please share your experience or usage example that verifies
improving performance?
2) Can I annotate @DataCache at superclass (@MappedSuperclass)?
Here's how I enable data cache:
Spring's context:
<bean id="entityManagerFactory"
class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
...
<property name="jpaPropertyMap">
<map>
<entry key="openjpa.DataCache"
value="true(name=read-only-cache, cacheSize=10000)"/>
<entry key="openjpa.RemoteCommitProvider" value="sjvm"/>
</map>
</property>
</bean>
Persistent object:
@javax.persistence.Entity
@Table(name = "foo")
@DataCache(name = "read-only-cache")
public class Foo ...
What else do I have to do (calling StoreCache.pin(), etc.)?
TIA,
Frank
--
View this message in context:
http://www.nabble.com/Data-cache-usage--tp14623378p14623378.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.