mirror of
https://github.com/hibernate/hibernate-orm
synced 2025-02-09 04:34:49 +00:00
HHH-16213 Avoid initializing lazy table group joins in AbstractSqlAstWalker
This commit is contained in:
parent
425879d9a7
commit
4d46294088
@ -434,7 +434,12 @@ public void visitTableGroup(TableGroup tableGroup) {
|
||||
|
||||
@Override
|
||||
public void visitTableGroupJoin(TableGroupJoin tableGroupJoin) {
|
||||
tableGroupJoin.getJoinedGroup().accept( this );
|
||||
final TableGroup joinedGroup = tableGroupJoin.getJoinedGroup();
|
||||
if ( joinedGroup.isInitialized() ) {
|
||||
// Only process already initialized table groups to avoid
|
||||
// forced initialization of joined lazy table groups
|
||||
joinedGroup.accept( this );
|
||||
}
|
||||
if ( tableGroupJoin.getPredicate() != null ) {
|
||||
tableGroupJoin.getPredicate().accept( this );
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user