More for AR-460: System concurrency

There might be a few SDK projects that still use TransactionUtil, but this checkin gets rid of
its use otherwise.
I took a glance over the areas of the code that use UserTransaction directly and didn't see any
transactionally wrapped code that desperately needed to be put into a retry loop (i.e. write
transactions in a concurrent scenario).  If you spot any that you think might qualify, let me know.


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6220 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2007-07-12 04:15:28 +00:00
parent 32054c773c
commit 0d1bd57217
31 changed files with 230 additions and 286 deletions

View File

@@ -42,8 +42,7 @@ import org.alfresco.model.ContentModel;
import org.alfresco.model.WCMAppModel;
import org.alfresco.repo.domain.PropertyValue;
import org.alfresco.repo.security.authentication.AuthenticationUtil;
import org.alfresco.repo.transaction.TransactionUtil;
import org.alfresco.repo.transaction.TransactionUtil.TransactionWork;
import org.alfresco.repo.transaction.RetryingTransactionHelper.RetryingTransactionCallback;
import org.alfresco.repo.workflow.WorkflowModel;
import org.alfresco.sandbox.SandboxConstants;
import org.alfresco.service.cmr.avm.AVMNodeDescriptor;
@@ -170,16 +169,15 @@ public class AVMExpiredContentProcessor
{
public String doWork() throws Exception
{
TransactionWork<String> expiredContentWork = new TransactionWork<String>()
RetryingTransactionCallback<String> expiredContentWork = new RetryingTransactionCallback<String>()
{
public String doWork() throws Exception
public String execute() throws Exception
{
processExpiredContent();
return null;
}
};
return TransactionUtil.executeInNonPropagatingUserTransaction(transactionService, expiredContentWork);
return transactionService.getRetryingTransactionHelper().doInTransaction(expiredContentWork);
}
};