mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Fix for ALF-10153 SQL Server: FK failures across various tests
- added retry for two concurrency issues on adding children git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@32768 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -2793,6 +2793,18 @@ public abstract class AbstractNodeDAOImpl implements NodeDAO, BatchingDAO
|
||||
catch (Throwable e)
|
||||
{
|
||||
controlDAO.rollbackToSavepoint(savepoint);
|
||||
// SQL Server retry
|
||||
|
||||
if(e.getMessage().contains("Snapshot isolation transaction aborted"))
|
||||
{
|
||||
throw new ConcurrencyFailureException("SQL Server snapshot isolation retry...", e);
|
||||
}
|
||||
|
||||
if(e.getMessage().contains("The INSERT statement conflicted with the FOREIGN KEY constraint"))
|
||||
{
|
||||
throw new ConcurrencyFailureException("SQL Server FK conflict retry...", e);
|
||||
}
|
||||
|
||||
// We assume that this is from the child cm:name constraint violation
|
||||
throw new DuplicateChildNodeNameException(
|
||||
parentNode.getNodeRef(),
|
||||
|
Reference in New Issue
Block a user