You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by el...@apache.org on 2022/08/28 22:43:06 UTC
[directory-server] branch master updated: Fixed some missing transaction propagation
This is an automated email from the ASF dual-hosted git repository.
elecharny pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/directory-server.git
The following commit(s) were added to refs/heads/master by this push:
new 4680b43424 Fixed some missing transaction propagation
4680b43424 is described below
commit 4680b43424c70cab970d539af3381cab5c9e4fea
Author: emmanuel lecharny <el...@apache.org>
AuthorDate: Mon Aug 29 00:42:48 2022 +0200
Fixed some missing transaction propagation
---
.../server/core/subtree/SubentryInterceptor.java | 16 +++++++++++-----
1 file changed, 11 insertions(+), 5 deletions(-)
diff --git a/interceptors/subtree/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java b/interceptors/subtree/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java
index 5db5782beb..b47a340f91 100644
--- a/interceptors/subtree/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java
+++ b/interceptors/subtree/src/main/java/org/apache/directory/server/core/subtree/SubentryInterceptor.java
@@ -1219,8 +1219,10 @@ public class SubentryInterceptor extends BaseInterceptor
if ( directoryService.getEvaluator().evaluate( ssNew, apName, candidateDn, candidate ) )
{
- nexus.modify( new ModifyOperationContext( modifyContext.getSession(), candidateDn,
- getOperationalModsForAdd( candidate, operationalAttributes ) ) );
+ ModifyOperationContext newModifyContext = new ModifyOperationContext( modifyContext.getSession(), candidateDn,
+ getOperationalModsForAdd( candidate, operationalAttributes ) );
+ newModifyContext.setTransaction( modifyContext.getTransaction() );
+ nexus.modify( newModifyContext );
}
}
subentries.close();
@@ -1521,7 +1523,9 @@ public class SubentryInterceptor extends BaseInterceptor
if ( !mods.isEmpty() )
{
- nexus.modify( new ModifyOperationContext( moveAndRenameContext.getSession(), newDn, mods ) );
+ ModifyOperationContext newModifyContext = new ModifyOperationContext( moveAndRenameContext.getSession(), newDn, mods );
+ newModifyContext.setTransaction( moveAndRenameContext.getTransaction() );
+ nexus.modify( newModifyContext );
}
}
}
@@ -1587,9 +1591,11 @@ public class SubentryInterceptor extends BaseInterceptor
if ( directoryService.getEvaluator().evaluate( ss, apName, dn, candidate ) )
{
- nexus.modify( new ModifyOperationContext( renameContext.getSession(), dn,
+ ModifyOperationContext newModifyContext = new ModifyOperationContext( renameContext.getSession(), dn,
getOperationalModsForReplace(
- oldDn, newName, subentry, candidate ) ) );
+ oldDn, newName, subentry, candidate ) );
+ newModifyContext.setTransaction( renameContext.getTransaction() );
+ nexus.modify( newModifyContext );
}
}
}