Improve deletion retry

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@3446 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Andrew Hind
2006-08-01 17:11:49 +00:00
parent 25123a4504
commit b2318d04f3

View File

@@ -1796,6 +1796,7 @@ public class IndexInfo
while (runnable) while (runnable)
{ {
String id = null; String id = null;
HashSet<String> fails = new HashSet<String>();
while ((id = deleteQueue.poll()) != null) while ((id = deleteQueue.poll()) != null)
{ {
if (s_logger.isDebugEnabled()) if (s_logger.isDebugEnabled())
@@ -1811,9 +1812,10 @@ public class IndexInfo
s_logger.debug("DELETE FAILED"); s_logger.debug("DELETE FAILED");
} }
// try again later // try again later
deleteQueue.add(id); fails.add(id);
} }
} }
deleteQueue.addAll(fails);
synchronized (this) synchronized (this)
{ {
try try