Child collection fetched using left outer join with on clause or where clause restrictions on fetched collection shouldn’t be stored in second level cache.

Description

Reproductions Steps:
1. Enable second level cache in nh configuration.
2. Create entity with collection.
3. Enable second level cache on collection (on collection entity also ofc).
4. Open session.
5. Create QueryOver (Criteria or HQL) which fetch root entities with children collections using left outer join with some restrictions on collection.
E.g.

6. Open another session.
7. Create QueryOver on second session for all root entities. E.g.

8. Iterate over entities fetched in point 7. and fetch child collections.
9. All collection fetched in point 8. Will be filtered like in point 5.

Environment

None

Assignee

Unassigned

Reporter

Lz

Labels

Components

Fix versions

Affects versions

Priority

Major
Configure