you must enable second level cache:
| <property name="hibernate.cache.use_second_level_cache"
value="true" />
|
And cache is used in that situations:
| Whenever you pass an object to save(), update() or saveOrUpdate() and whenever you
retrieve an object using load(), get(), list(), iterate() or scroll(), that object is
added to the internal cache of the Session.
|
http://www.hibernate.org/hib_docs/reference/en/html/performance.html
Maybe you are using session.createQuery which uses cache in different ways.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4166786#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...