From 1439e4a9a89cb9af2f2449d2f07f0b88056d7da3 Mon Sep 17 00:00:00 2001 From: Marco Belladelli Date: Mon, 13 Nov 2023 14:56:04 +0100 Subject: [PATCH] HHH-17313 Always get Boolean wrapper for HINT_READ_ONLY --- .../java/org/hibernate/boot/model/internal/QueryBinder.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hibernate-core/src/main/java/org/hibernate/boot/model/internal/QueryBinder.java b/hibernate-core/src/main/java/org/hibernate/boot/model/internal/QueryBinder.java index b8a634faf3..081f52ebbe 100644 --- a/hibernate-core/src/main/java/org/hibernate/boot/model/internal/QueryBinder.java +++ b/hibernate-core/src/main/java/org/hibernate/boot/model/internal/QueryBinder.java @@ -93,7 +93,7 @@ public abstract class QueryBinder { .setTimeout( hints.getTimeout() ) .setFetchSize( hints.getInteger( HibernateHints.HINT_FETCH_SIZE ) ) .setFlushMode( hints.getFlushMode() ) - .setReadOnly( hints.getBoolean( HibernateHints.HINT_READ_ONLY ) ) + .setReadOnly( hints.getBooleanWrapper( HibernateHints.HINT_READ_ONLY ) ) .setLockOptions( hints.determineLockOptions( namedQuery ) ) .setComment( hints.getString( HibernateHints.HINT_COMMENT ) ) .build(); @@ -140,7 +140,7 @@ public abstract class QueryBinder { .setTimeout( hints.getTimeout() ) .setFetchSize( hints.getInteger( HibernateHints.HINT_FETCH_SIZE ) ) .setFlushMode( hints.getFlushMode() ) - .setReadOnly( hints.getBoolean( HibernateHints.HINT_READ_ONLY ) ) + .setReadOnly( hints.getBooleanWrapper( HibernateHints.HINT_READ_ONLY ) ) .setComment( hints.getString( HibernateHints.HINT_COMMENT ) ) .addHints( hints.getHintsMap() );