Hi there!
I would like to ask how to configure QueryCache in the ehcache.xml?
Quote:
WARN [net.sf.ehcache.hibernate.Plugin] Could not find configuration for net.sf.hibernate.cache.QueryCache. Configuring using the defaultCache settings.
In addition, what is this cache region?
Code:
query.setCacheable(true).setCacheRegion("cahe-region");
and where I have to configure it?
In the
14.3.1. Cache mappings said:
"Alternatively (preferrably?), you may specify <class-cache> and <collection-cache> elements in hibernate.cfg.xml."
Can anybody share an example of <class-cahe>,<collection-cache> configuration? And is this configuration an alternative or preferrable one? I think that using class-cahe and collection-cache is preferrable approach, I don't like to mix mapping and cache configuration in hbm.xml files, for me it would be more suitable to configure caches in the hibernate.cfg.xml and ehcache.xml.
Thanks,
Leonid