Question

This Hibernate configuration ostensibly should control how many objects are cached in the first level cache. The reason is easy enough to understand, we don't want to run out of memory.

But something is confusing me. Every implementation I have seen including this website has an explicit flush and clear. No problem, but then what's point of the configuration property?

Note: I'm assuming here is that somehow Hibernate monitors the size of the cache and if the number of objects of a certain type grows to be larger than the cache size then synchronize the cache with the db. Don't know if that assumption is wrong ???

No correct solution

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top