Hi,
i opened 2.level cache and query cache in persistence.xml like following:
                        <property name="hibernate.show_sql" value="true" />
  |                     <property name="hibernate.cache.provider_class" 
value="org.jboss.ejb3.entity.TreeCacheProviderHook"/>
  |                 <property name="hibernate.treecache.mbean.object_name" 
value="jboss.cache:service=EJB3EntityTreeCache"/>
  |                     <property name="hibernate.cache.use_query_cache" 
value="true" />

and on an entity: 
@Cache(usage = CacheConcurrencyStrategy.NONSTRICT_READ_WRITE)
for 2. level cache

and 

        query.setParameter("vorname", vorname).setParameter("nachname",
  |             nachname).setMaxResults(maxResults).setFirstResult(firstResult)
  |             .setHint("org.hibernate.cacheable", new 
Boolean(true)).setHint("org.hibernate.cacheMode", CacheMode.GET 
).setHint("org.hibernate.fetchSize", new Integer(100));
  | 
for query cache...

but it doese not work :(

can anyone help?

thanks in advance

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

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4025010
_______________________________________________
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to