You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Simplify code flow. Introduce flag to capture whether a stored procedure uses collection return types.
Remove unconditionally the Optional converter as we're already on Java 17 and do not require the Java 8 guard.
See #2915
Original pull request: #2938
privatestaticfinalStringNO_SURROUNDING_TRANSACTION = "You're trying to execute a @Procedure method without a surrounding transaction that keeps the connection open so that the ResultSet can actually be consumed; Make sure the consumer code uses @Transactional or any other way of declaring a (read-only) transaction";
if (storedProcedureinstanceofAutoCloseableautoCloseable) {
359
+
if (procedureinstanceofAutoCloseableac) {
360
360
try {
361
-
autoCloseable.close();
361
+
ac.close();
362
362
} catch (Exceptionignored) {}
363
363
}
364
364
}
@@ -375,10 +375,10 @@ static class StreamExecution extends JpaQueryExecution {
375
375
376
376
privatestaticfinalStringNO_SURROUNDING_TRANSACTION = "You're trying to execute a streaming query method without a surrounding transaction that keeps the connection open so that the Stream can actually be consumed; Make sure the code consuming the stream uses @Transactional or any other way of declaring a (read-only) transaction";
0 commit comments