chihsuan opened a new pull request, #11713: URL: https://github.com/apache/ozone/pull/11713
## What changes were proposed in this pull request? The stale recovering scrub marks a container UNHEALTHY based only on its `recoveringContainerMap` entry. If the container was closed in the meantime, a valid reconstructed EC replica becomes UNHEALTHY and SCM has to reconstruct it again. This also covers HDDS-16456, where a write re-adds the entry right after the close. This PR re-checks the state under the container write lock and only marks the container UNHEALTHY if it is still RECOVERING. ## What is the link to the Apache JIRA https://issues.apache.org/jira/browse/HDDS-16455 ## How was this patch tested? https://github.com/chihsuan/ozone/actions/runs/39928857486 Added three tests to `TestStaleRecoveringContainerScrubbingService`: - `testScrubSkippedWhenContainerClosedBeforeTaskRuns`: the container closes before the scrub task runs. - `testScrubSkippedForStaleEntryOfClosedContainer`: a stale entry is left after the close. - `testScrubDoesNotOverrideConcurrentClose`: a close runs while the scrub task is waiting on the lock. Generated-by: Claude Code (Claude Opus 5.5) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
