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

Aryan Gupta updated HDDS-16283:
-------------------------------
    Summary: Fix flakiness in trash root prepare failure test  (was: Stabilize 
testMoveToTrashAbortTaskWhenTrashRootPrepareFails by removing nondeterministic 
success-metric assertion)

> Fix flakiness in trash root prepare failure test
> ------------------------------------------------
>
>                 Key: HDDS-16283
>                 URL: https://issues.apache.org/jira/browse/HDDS-16283
>             Project: Apache Ozone
>          Issue Type: Improvement
>            Reporter: Aryan Gupta
>            Assignee: Aryan Gupta
>            Priority: Major
>
> {{testMoveToTrashAbortTaskWhenTrashRootPrepareFails}} is flaky because it 
> asserts that {{KeyLifecycleServiceMetrics#getNumSuccessTask()}} does not 
> change. That metric is globally registered/shared, so concurrent lifecycle 
> task execution in other parameterized runs can increment it, leading to 
> intermittent failures (for example {{{}expected: <41> but was: <42>{}}}).
> The test has been updated to validate deterministic, local behavior instead 
> of shared global metrics:
>  * capture the created key,
>  * inject trash-root preparation failure,
>  * run {{{}LifecycleActionTask{}}},
>  * assert expected failure logs are present,
>  * assert the original key still exists and key count is unchanged.



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

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to