From 3e295a9e8038be1d3c5dd2b3c1271bdd17037b73 Mon Sep 17 00:00:00 2001 From: Jens Schauder Date: Wed, 8 Jan 2025 15:33:21 +0100 Subject: [PATCH] Adapt to API changes in Spring Framework. The constructor for DefaultTransaction now requires a name and `nested` flag. Closes #2016 --- .../CouchbaseTransactionStatus.java | 48 ++++++++++--------- 1 file changed, 25 insertions(+), 23 deletions(-) diff --git a/src/main/java/org/springframework/data/couchbase/transaction/CouchbaseTransactionStatus.java b/src/main/java/org/springframework/data/couchbase/transaction/CouchbaseTransactionStatus.java index 19641cda8..cd619f345 100644 --- a/src/main/java/org/springframework/data/couchbase/transaction/CouchbaseTransactionStatus.java +++ b/src/main/java/org/springframework/data/couchbase/transaction/CouchbaseTransactionStatus.java @@ -24,27 +24,29 @@ */ public class CouchbaseTransactionStatus extends DefaultTransactionStatus { - /** - * Create a new {@code DefaultTransactionStatus} instance. - * - * @param transaction underlying transaction object that can hold state - * for the internal transaction implementation - * @param newTransaction if the transaction is new, otherwise participating - * in an existing transaction - * @param newSynchronization if a new transaction synchronization has been - * opened for the given transaction - * @param readOnly whether the transaction is marked as read-only - * @param debug should debug logging be enabled for the handling of this transaction? - * Caching it in here can prevent repeated calls to ask the logging system whether - * debug logging should be enabled. - * @param suspendedResources a holder for resources that have been suspended - */ - public CouchbaseTransactionStatus(Object transaction, boolean newTransaction, boolean newSynchronization, boolean readOnly, boolean debug, Object suspendedResources) { - super(transaction, - newTransaction, - newSynchronization, - readOnly, - debug, - suspendedResources); - } + /** + * Create a new {@code DefaultTransactionStatus} instance. + * + * @param transaction underlying transaction object that can hold state + * for the internal transaction implementation + * @param newTransaction if the transaction is new, otherwise participating + * in an existing transaction + * @param newSynchronization if a new transaction synchronization has been + * opened for the given transaction + * @param readOnly whether the transaction is marked as read-only + * @param debug should debug logging be enabled for the handling of this transaction? + * Caching it in here can prevent repeated calls to ask the logging system whether + * debug logging should be enabled. + * @param suspendedResources a holder for resources that have been suspended + */ + public CouchbaseTransactionStatus(Object transaction, boolean newTransaction, boolean newSynchronization, boolean readOnly, boolean debug, Object suspendedResources) { + super(null, + transaction, + newTransaction, + newSynchronization, + false, + readOnly, + debug, + suspendedResources); + } }