cache « Glassfish « JPA Q&A

1. Glassfish with infinispan second level caching

I want to use Infinispan with hibernate second level cache. My application is running in a glassfish 3 application server and I use hibernate JPA. The hibernate library already contains infinispan ...

2. JPA Cache evict all instances of a given class

We have a number of entities that are generated from scheduled process that writes directly to the database. I would like to be able to flush the database of all instances of the Class that is updated so that they entity manager will recreate the instance in its cache the next time a query is created.