Merged V3.2 to HEAD

15341: Update svn:mergeinfo
   15220: NestedSQLException containing causal exceptions with word "deadlock" will trigger a retry
          Added "constraint" search as part of the merge
   15565: Update svn:mergeinfo
   15569: Merge 3.1 to 3.2:
      15231: Fix for cut/paste file between folders on CIFS. ETHREEOH-2323, + ENH-515. (Record only)
___________________________________________________________________
Modified: svn:mergeinfo
   Merged /alfresco/BRANCHES/V3.1:r14561-14562,14922,15155,15233-15234,15258,15326
   Merged /alfresco/BRANCHES/V3.2:r15231,15341,15520,15565,15569



git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@16857 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley
2009-10-13 11:20:19 +00:00
parent e10bf8da0d
commit 69f987c456

View File

@@ -101,6 +101,7 @@ public class RetryingTransactionHelper
ConstraintViolationException.class,
UncategorizedSQLException.class,
SQLException.class,
NestedSQLException.class,
BatchUpdateException.class,
DataIntegrityViolationException.class,
StaleStateException.class,
@@ -479,6 +480,17 @@ public class RetryingTransactionHelper
{
// We dig further into this
cause = retryCause.getCause();
// Check for SQL-related "deadlock" messages
if (retryCause.getMessage().toLowerCase().contains("deadlock"))
{
// The word "deadlock" is usually an indication that we need to resolve with a retry.
return retryCause;
}
else if (retryCause.getMessage().toLowerCase().contains("constraint"))
{
// The word "constraint" is also usually an indication or a concurrent update
return retryCause;
}
// Recurse
return extractRetryCause(cause);
}