You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Woonsan Ko (JIRA)" <ji...@apache.org> on 2016/08/29 12:35:20 UTC

[jira] [Updated] (JCR-4008) Restore TestCachingFDS.testDeleteRecord() to fix it without aync writing

     [ https://issues.apache.org/jira/browse/JCR-4008?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Woonsan Ko updated JCR-4008:
----------------------------
    Description: 
The test used to fail occasionally before the test method was commented out by JCR-4006:
{noformat}
junit.framework.AssertionFailedError: rec2 should be null
	at junit.framework.Assert.fail(Assert.java:50)
	at junit.framework.Assert.assertTrue(Assert.java:20)
	at junit.framework.Assert.assertNull(Assert.java:237)
	at org.apache.jackrabbit.core.data.TestCaseBase.doDeleteRecordTest(TestCaseBase.java:327)
	at org.apache.jackrabbit.core.data.TestCaseBase.testDeleteRecord(TestCaseBase.java:192)
{noformat}

The main reason of this error is because the underlying backend uses asynchronous writing threads by default, which is not working well when extending {{org.apache.jackrabbit.core.data.TestCaseBase}} as mentioned in JCR-4005.
So, it seems better to fix it again like the following like how JCR-4005 was fixed:
- Restore the commented out block (
- Provide an option to disable asynchronous writing in all the related backend implementations. e.g., disable it if {{asyncWritePoolSize}} is zero or smaller.
- In unit tests, simply disable async writing.


> Restore TestCachingFDS.testDeleteRecord() to fix it without aync writing
> ------------------------------------------------------------------------
>
>                 Key: JCR-4008
>                 URL: https://issues.apache.org/jira/browse/JCR-4008
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>            Reporter: Woonsan Ko
>
> The test used to fail occasionally before the test method was commented out by JCR-4006:
> {noformat}
> junit.framework.AssertionFailedError: rec2 should be null
> 	at junit.framework.Assert.fail(Assert.java:50)
> 	at junit.framework.Assert.assertTrue(Assert.java:20)
> 	at junit.framework.Assert.assertNull(Assert.java:237)
> 	at org.apache.jackrabbit.core.data.TestCaseBase.doDeleteRecordTest(TestCaseBase.java:327)
> 	at org.apache.jackrabbit.core.data.TestCaseBase.testDeleteRecord(TestCaseBase.java:192)
> {noformat}
> The main reason of this error is because the underlying backend uses asynchronous writing threads by default, which is not working well when extending {{org.apache.jackrabbit.core.data.TestCaseBase}} as mentioned in JCR-4005.
> So, it seems better to fix it again like the following like how JCR-4005 was fixed:
> - Restore the commented out block (
> - Provide an option to disable asynchronous writing in all the related backend implementations. e.g., disable it if {{asyncWritePoolSize}} is zero or smaller.
> - In unit tests, simply disable async writing.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)