Hi guys. I'm just now beginning to play with the second-level cache stuff. I can of course see how to configure caching for my objects in their .hbm.xml mapping files, but what is the best practice if I want different cache strategies for different contexts? For example, in my public servlet, I might want some mostly immutable objects to be cached read-only. But in my command-line admin tool, I'd obviously not want a read-only cache.
Is this possible? Is it recommended? (e.g. different SessionFactories, perhaps in separate JVM's, accessing the same data store, perhaps with different caching strategies)
|