[ 
https://issues.apache.org/jira/browse/OAK-12444?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18124785#comment-18124785
 ] 

Rishabh Daim commented on OAK-12444:
------------------------------------

Fixed in [PR #3200|https://github.com/apache/jackrabbit-oak/pull/3200], with a 
seven-line test-only change on latest trunk. Full oak-run suite: 288 tests, 9 
skipped, no failures. All eight old/recent-reference checks passed across 
Mongo/SegmentTar and FileDataStore/S3Mock. Amit Jain and Julian Reschke 
requested as reviewers.


> Fix reference-retention timing in DataStoreCommandTest
> ------------------------------------------------------
>
>                 Key: OAK-12444
>                 URL: https://issues.apache.org/jira/browse/OAK-12444
>             Project: Jackrabbit Oak
>          Issue Type: Bug
>            Reporter: Rishabh Daim
>            Assignee: Rishabh Daim
>            Priority: Major
>
> DataStoreCommandTest.gcSweepRefsOld intermittently fails because GC skips 
> sweeping and does not create avail- output. The latest failure used 
> SegmentTar with FileDataStore: [CI 
> failure|https://github.com/apache/jackrabbit-oak/actions/runs/37638190443/job/112849844984?pr=3195].
> The test assumes a new reference record is already old enough for 
> zero-retention GC. Production correctly requires lastModified < cutoff; equal 
> timestamps reject the sweep. The earlier setup delay happens before marking 
> and cannot guarantee this condition.
> Fix the test by completing a mark-only pass and waiting past its stored 
> reference timestamp before sweeping. Keep the output and blob-deletion 
> assertions and the recent-reference test unchanged. No production changes are 
> needed.
> On current trunk, forcing the GC cutoff to the newest reference timestamp 
> reproduces the exact missing avail- failure on both FileDataStore fixtures. 
> The proposed test setup passes the same controlled experiment.
> The test originated in OAK-9040 (commit 
> 3594f92a47020329f137330f03ee16ee8e4a9572). OAK-12122 reported the same 
> failure before S3Mock coverage; its fix added a deterministic random seed and 
> diagnostics but did not address reference age. Slow real AWS S3 requests can 
> hide this timing assumption.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to