-
Bug
-
Resolution: Done
-
Major
-
4.12.0, 4.6.1.CP06
-
None
jts.TransactionImple constructors attempt to optimize the cleanup callback needed to remove entries from _transactions, bypassing the ORB for interposition scenarios:
theTx = (TwoPhaseCoordinator) BasicAction.Current();
if (theTx != null) {
theTx.addSynchronization(new LocalCleanupSynchronization(this));
} else {
registerSynchronization(new CleanupSynchronization(this));
}
Unfortunately this does not work and leads to memory leaks on _transactions in certain cases. Specifically, where theTx is a ServerTransaction (i.e. extends ArjunaTransactionImple, which extends TwoPhaseCoordinator), the callbacks run (by ArjunaTransactionImple.do[Before|After]Completion()) are those in ArjunaTransactionImple._syncs, not the masked ones in TwoPhaseCoordinator._syncs. Thus using TwoPhaseCoordinator.addSynchronization registers a callback which is never invoked.
- blocks
-
JBPAPP-4726 JBoss crushes with OutOfMemory error when running under heavy load with XA transactions (JTS implementation) that span two JBoss AS instances.
- Closed