ci: add retry for flaky network operations (cargo test, docker compose)#7703
Open
TennyZhuang wants to merge 2 commits into
Open
ci: add retry for flaky network operations (cargo test, docker compose)#7703TennyZhuang wants to merge 2 commits into
TennyZhuang wants to merge 2 commits into
Conversation
tisonkun
requested changes
Jun 7, 2026
Member
tisonkun
left a comment
There was a problem hiding this comment.
+1 for docker compose retey
-1 for test retry
CI can be re run with a empty commit or committer's triggering on UI.
Retry tests may hide the real issue. For certain unstable tests, we can add retry in the test cases instead.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rationale
We observed flaky CI failures caused by transient network issues:
cargo testfailing to fetch crates from crates.io (SSL EOF, HTTP2 framing errors)docker compose upfailing to pull images from Docker Hub (connection timeout, registry access denied)These failures are unrelated to code changes and waste CI time on retries.
Changes
.github/actions/test_behavior_core/action.yaml: Wrapcargo testin a retry loop (3 attempts, exponential backoff).github/services/hdfs_native/hdfs_native_cluster/action.yml: Wrapdocker compose upin a retry loop (3 attempts, exponential backoff, clean up on failure)Testing
The retry logic is conservative: 3 attempts with
sleep(i * 10)backoff, which should handle most transient network blips without significantly extending CI time for persistent failures.