[
https://issues.apache.org/jira/browse/HDDS-15823?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Siyao Meng updated HDDS-15823:
------------------------------
Status: Patch Available (was: Open)
> Fix flaky
> TestFailureHandlingByClient#testContainerExclusionWithClosedContainerException
> ----------------------------------------------------------------------------------------
>
> Key: HDDS-15823
> URL: https://issues.apache.org/jira/browse/HDDS-15823
> Project: Apache Ozone
> Issue Type: Bug
> Components: test
> Reporter: Siyao Meng
> Assignee: Siyao Meng
> Priority: Major
> Labels: pull-request-available
>
> Generated-by: Claude Code (Opus 4.8)
> {{TestFailureHandlingByClient#testContainerExclusionWithClosedContainerException}}
> fails intermittently with {{Expecting empty but was: [Pipeline-...]}} on the
> assertion that the client exclude list holds no pipeline IDs (seen in
> upstream CI on 2026-07-06, after HDDS-15605 removed the analogous datanodes
> assertion).
> The test forces a container to close and writes again, expecting a
> {{ClosedContainerException}} that adds only the container to the exclude
> list. Under the default {{ALL_COMMITTED}} watch level, a slow or unavailable
> follower can instead surface a WATCH {{RaftRetryFailureException}}. In
> {{KeyOutputStream.handleException}}, {{checkForRetryFailure}} returns true
> for that exception, so the container exclusion branch is skipped and the else
> branch adds the pipeline to the exclude list. That is intended client
> behavior, so an empty pipeline set is not an invariant for this configuration.
> Fix: remove the {{getPipelineIds().isEmpty()}} assertion, consistent with how
> HDDS-15605 handled the datanodes case, and add a comment explaining why the
> pipeline set is not an invariant here. The container ID exclusion assertion,
> which is the actual property under test, is retained. The change is limited
> to the test.
> Testing: ran the test 100 times locally with 0 failures, each run confirmed
> to execute the method ({{Tests run: 1, Failures: 0, Errors: 0}}). Ran the
> full {{TestFailureHandlingByClient}} class (6 tests, 0 failures). Checkstyle
> clean.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]