You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Philippe Mouawad (JIRA)" <ji...@apache.org> on 2009/04/17 14:38:14 UTC

[jira] Commented: (OFBIZ-2315) TransactionUtil : 3 Map corruptions related to mis synchronization

    [ https://issues.apache.org/jira/browse/OFBIZ-2315?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12700153#action_12700153 ] 

Philippe Mouawad commented on OFBIZ-2315:
-----------------------------------------

After analysis, we can see that 2 maps : 
- allThreadsTransactionBeginStack
- allThreadsTransactionBeginStackSave

Are not synchronized and can be accessed (corrupted) from non synchronized blocks.

This IMHO provokes corruption of FastMap and explains why the FastMap.resizeTable has been running for so long.

> TransactionUtil : 3 Map corruptions related to mis synchronization
> ------------------------------------------------------------------
>
>                 Key: OFBIZ-2315
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-2315
>             Project: OFBiz
>          Issue Type: Bug
>    Affects Versions: Release Branch 4.0, SVN trunk
>            Reporter: Philippe Mouawad
>         Attachments: ContentionLog.txt
>
>
> Randomly we are having Thread contention problems in production related to synchronization issues in this class.
> See attached log file.
> As you can see, a lot of threads are locked by some code called by TransactionUtil.setTransactionBeginStack that has been running for 180165 ms :
> Thread[default-invoker-Thread-4582999,5,main]:4590333, stackTrace:
> 	javolution.util.FastMap.mapEntry(Unknown Source)
> 	javolution.util.FastMap.access$1200(Unknown Source)
> 	javolution.util.FastMap$3.run(Unknown Source)
> 	javax.realtime.MemoryArea.executeInArea(Unknown Source)
> 	javolution.util.FastMap.resizeTable(Unknown Source)
> 	javolution.util.FastMap.mapEntry(Unknown Source)
> 	javolution.util.FastMap.addEntry(Unknown Source)
> 	javolution.util.FastMap.put(Unknown Source)
> 	org.ofbiz.entity.transaction.TransactionUtil.setTransactionBeginStack(TransactionUtil.java:657)
> 	org.ofbiz.entity.transaction.TransactionUtil.setTransactionBeginStack(TransactionUtil.java:646)
> 	org.ofbiz.entity.transaction.TransactionUtil.begin(TransactionUtil.java:135)
> 	org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:297)
> 	org.ofbiz.service.ServiceDispatcher.runSync(ServiceDispatcher.java:208)
> 	org.ofbiz.service.GenericDispatcher.runSync(GenericDispatcher.java:149)
> 	org.ofbiz.service.job.GenericServiceJob.exec(GenericServiceJob.java:69)
> 	org.ofbiz.service.job.JobInvoker.run(JobInvoker.java:240)
> 	java.lang.Thread.run(Thread.java:595)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.