Skip to content

Commit 8a88ad7

Browse files
noetrombellade
authored andcommitted
HHH-18571 Fix bug and correctly report effective batching
1 parent ff1d5fd commit 8a88ad7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

hibernate-core/src/main/java/org/hibernate/engine/spi/LoadQueryInfluencers.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ public int effectiveBatchSize(CollectionPersister persister) {
325325
}
326326

327327
public boolean effectivelyBatchLoadable(CollectionPersister persister) {
328-
return batchSize > 1 || persister.isBatchLoadable();
328+
return persister.isBatchLoadable() || effectiveBatchSize( persister ) > 1;
329329
}
330330

331331
public int effectiveBatchSize(EntityPersister persister) {
@@ -336,7 +336,7 @@ public int effectiveBatchSize(EntityPersister persister) {
336336
}
337337

338338
public boolean effectivelyBatchLoadable(EntityPersister persister) {
339-
return batchSize > 1 || persister.isBatchLoadable();
339+
return persister.isBatchLoadable() || effectiveBatchSize( persister ) > 1;
340340
}
341341

342342
public boolean getSubselectFetchEnabled() {

0 commit comments

Comments
 (0)