| When using the session.byMultipleIds(...).enableSessionCheck(true).multiLoad(...) to load a set of entities that are already cached in the 2nd level cache a full query against the database is performed. I would have expected either another flag such as enableSecondLevelCacheCheck() to enable checking of the second level cache or for the cache to be checked automatically when the sessionCheck() is enabled. Otherwise When using immutable entities this type of feature could avoid a great deal of work is done to pull back entities from the database that could potentially be avoided load . |
|