Merged HEAD (5.1) to 5.1.N (5.1.1)

116653 sglover: ACE-4347 "5.1 Build has had three transient failures related to locking"
   Increase the logging for the failing tests to DEBUG so that we can see what's happening during the next failure


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.1.N/root@117202 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Tatyana Valkevych
2015-11-11 12:03:42 +00:00
parent 9fe591aca0
commit a5f0efb1d4

View File

@@ -404,7 +404,10 @@ public class JobLockServiceTest extends TestCase
// Check that the timed callback is killed properly
int checkedCount = checked[0];
int releasedCount = released[0];
System.out.println("X:" + checkedCount + ":" + releasedCount);
if(logger.isDebugEnabled())
{
logger.debug("checkedCount=" + checkedCount + ",releasedCount=" + releasedCount);
}
wait(10000L);
assertEquals("Lock callback timer was not terminated", checkedCount, checked[0]);
assertEquals("Lock callback timer was not terminated", releasedCount, released[0]);
@@ -485,7 +488,11 @@ public class JobLockServiceTest extends TestCase
public void testGetLockWithCallbackNormal() { runGetLockWithCallback(4); }
public void runGetLockWithCallback(int t)
{
{
// ACE-4347 extra debug logging just for this test so we can see what's going on when it next fails
Level saveLogLevel = Logger.getLogger("org.alfresco.repo.lock").getLevel();
Logger.getLogger("org.alfresco.repo.lock").setLevel(Level.ALL);
logger.debug("runGetLockWithCallback "+t+
"\n----------------------------------------"+
"\n"+Thread.currentThread().getStackTrace()[2].getMethodName()+
@@ -577,6 +584,8 @@ public class JobLockServiceTest extends TestCase
}
logger.debug("runGetLockWithCallback\n----------------------------------------");
Logger.getLogger("org.alfresco.repo.lock").setLevel(saveLogLevel);
}
}