Skip to content

Commit

Permalink
https://github.com/atomikos/transactions-essentials/issues/222
Browse files Browse the repository at this point in the history
Avoid prepare call to the Coordinator for recursions and RequiresNew

(cherry picked from commit 54ee920)
  • Loading branch information
martinaubele committed Jun 26, 2024
1 parent a54d11f commit 18e695d
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,13 @@ public void doRollback()
count = participants.size ();
result = new PrepareResult ( count );
Enumeration<Participant> enumm = participants.elements ();
String rootId = getCoordinator().getRootId();
while ( enumm.hasMoreElements () ) {
Participant p = (Participant) enumm.nextElement ();

// Fix for recursive call to rootId
if (rootId != null && p.getURI() != null && p.getURI().endsWith(rootId))
break;
PrepareMessage pm = new PrepareMessage ( p, result );
if ( getCascadeList () != null && p.getURI () != null ) { //null for OTS
Integer sibnum = (Integer) getCascadeList ().get ( p.getURI () );
Expand Down

0 comments on commit 18e695d

Please sign in to comment.