Fixed bug in using STM together with Active Objects
This commit is contained in:
parent
4dabf49b52
commit
2cdfdb2e26
15 changed files with 152 additions and 111 deletions
|
|
@ -156,8 +156,13 @@ class GlobalStm extends TransactionManagement with Logging {
|
|||
val result = body
|
||||
val txSet = getTransactionSetInScope
|
||||
log.ifTrace("Committing global transaction [" + mtx + "]\n\tand joining transaction set [" + txSet + "]")
|
||||
try {
|
||||
txSet.tryJoinCommit(
|
||||
mtx,
|
||||
TransactionConfig.DefaultTimeout.length,
|
||||
TransactionConfig.DefaultTimeout.unit)
|
||||
// Need to catch IllegalStateException until we have fix in Multiverse, since it throws it by mistake
|
||||
try { txSet.tryJoinCommit(mtx, TransactionConfig.TIMEOUT, TimeUnit.MILLISECONDS) } catch { case e: IllegalStateException => {} }
|
||||
} catch { case e: IllegalStateException => {} }
|
||||
result
|
||||
}
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue