From d8a756cf1b53d1e1e0f28c84bda38f143f0dac44 Mon Sep 17 00:00:00 2001 From: Stefano Ottolenghi Date: Fri, 29 Dec 2023 08:10:33 +0100 Subject: [PATCH 1/3] Clarify behavior of `executeWriteWithoutResult()`. --- driver/src/main/java/org/neo4j/driver/Session.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/driver/src/main/java/org/neo4j/driver/Session.java b/driver/src/main/java/org/neo4j/driver/Session.java index 41eee27751..c0687f476d 100644 --- a/driver/src/main/java/org/neo4j/driver/Session.java +++ b/driver/src/main/java/org/neo4j/driver/Session.java @@ -175,7 +175,7 @@ default T executeWrite(TransactionCallback callback) { * The driver will attempt committing the transaction when the provided unit of work completes successfully. Any exception emitted by the unit of work * will result in a rollback attempt. *

- * The provided unit of work should not return {@link Result} object as it won't be valid outside the scope of the transaction. + * This method works equivalently to {@link #executeWrite(TransactionCallback)}, but it allows for void returns. * * @param contextConsumer the consumer representing the unit of work. */ @@ -223,7 +223,7 @@ default void executeWriteWithoutResult(Consumer contextConsu * The driver will attempt committing the transaction when the provided unit of work completes successfully. Any exception emitted by the unit of work * will result in a rollback attempt and abortion of execution unless exception is considered to be valid for retry attempt by the driver. *

- * The provided unit of work should not return {@link Result} object as it won't be valid outside the scope of the transaction. + * This method works equivalently to {@link #executeWrite(TransactionCallback, TransactionConfig)}, but it allows for void returns. * * @param contextConsumer the consumer representing the unit of work. * @param config the transaction configuration for the managed transaction. From 633fcf5b46b75dd5228c75aa9d11b5db39aeebf9 Mon Sep 17 00:00:00 2001 From: Dmitriy Tverdiakov <11927660+injectives@users.noreply.github.com> Date: Mon, 29 Jan 2024 15:02:05 +0000 Subject: [PATCH 2/3] Update driver/src/main/java/org/neo4j/driver/Session.java --- driver/src/main/java/org/neo4j/driver/Session.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/driver/src/main/java/org/neo4j/driver/Session.java b/driver/src/main/java/org/neo4j/driver/Session.java index c0687f476d..1987321712 100644 --- a/driver/src/main/java/org/neo4j/driver/Session.java +++ b/driver/src/main/java/org/neo4j/driver/Session.java @@ -175,7 +175,7 @@ default T executeWrite(TransactionCallback callback) { * The driver will attempt committing the transaction when the provided unit of work completes successfully. Any exception emitted by the unit of work * will result in a rollback attempt. *

- * This method works equivalently to {@link #executeWrite(TransactionCallback)}, but it allows for void returns. + * This method works equivalently to {@link #executeWrite(TransactionCallback)}, but does not have a return value. * * @param contextConsumer the consumer representing the unit of work. */ From 647437be4e43d16691692b1175f2a776e156bbfa Mon Sep 17 00:00:00 2001 From: Dmitriy Tverdiakov <11927660+injectives@users.noreply.github.com> Date: Mon, 29 Jan 2024 15:02:11 +0000 Subject: [PATCH 3/3] Update driver/src/main/java/org/neo4j/driver/Session.java --- driver/src/main/java/org/neo4j/driver/Session.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/driver/src/main/java/org/neo4j/driver/Session.java b/driver/src/main/java/org/neo4j/driver/Session.java index 1987321712..b1db6f652d 100644 --- a/driver/src/main/java/org/neo4j/driver/Session.java +++ b/driver/src/main/java/org/neo4j/driver/Session.java @@ -223,7 +223,7 @@ default void executeWriteWithoutResult(Consumer contextConsu * The driver will attempt committing the transaction when the provided unit of work completes successfully. Any exception emitted by the unit of work * will result in a rollback attempt and abortion of execution unless exception is considered to be valid for retry attempt by the driver. *

- * This method works equivalently to {@link #executeWrite(TransactionCallback, TransactionConfig)}, but it allows for void returns. + * This method works equivalently to {@link #executeWrite(TransactionCallback, TransactionConfig)}, but does not have a return value. * * @param contextConsumer the consumer representing the unit of work. * @param config the transaction configuration for the managed transaction.