Anyone ever configured Play framework to use Memcached for Jpa cache?
my application.conf looks like this:
hibernate.cache.provider_class=com.googlecode.hibernate.memcached.MemcachedCacheProvider
hibernate.cache.region.factory_class=net.sf.ehcache.hibernate.EhCacheRegionFactory
hibernate.memcached.servers=127.0.0.1:11211
hibernate.memcached.cacheTimeSeconds=300
hibernate.cache.use_second_level_cache=true
hibernate.cache.use_query_cache=true
hibernate.generate_statistics=true
hibernate.cache.use_structured_entries=true
Memecached service is running with 2GB of memory allocated but only 2MB is used.
When applicaiton starts I see the following:
13:39:11,894 INFO ~ Connected to memcached
13:39:12,121 INFO ~ Connected to jdbc:postgresql://localhost/comdb
13:39:13,183 WARN ~ Couldn't find a specific ehcache configuration for cache named [item_instance]; using defaults.
13:39:13,259 WARN ~ Couldn't find a specific ehcache configuration for cache named [models.items.Item]; using defaults.
1. Wy it gives me warnings about Ehcache if I configured it to use memcached class?
2. There's no memcached region factory class so I have to use
hibernate.cache.region.factory_class=net.sf.ehcache.hibernate.EhCacheRegionFactory
Is that correct?
Thanks.