Hyukjin Kwon created SPARK-57959:
------------------------------------

             Summary: Deflake MetricsFailureInjectionSuite non-deterministic 
stage block failure injection test
                 Key: SPARK-57959
                 URL: https://issues.apache.org/jira/browse/SPARK-57959
             Project: Spark
          Issue Type: Test
          Components: SQL
    Affects Versions: 5.0.0
            Reporter: Hyukjin Kwon


MetricsFailureInjectionSuite 'Non-deterministic stage block failure injection - 
injectFailure=true' is flaky (~1/6 in the full suite; passes 10/10 in 
isolation). Evidence from macOS diagnostics: the failing run shows stage1=300 
stage2=5 (a clean run, no recompute) and completes in ~370ms vs ~860ms on a 
passing run, and the test's own shuffle receives no injected FetchFailed. The 
INJECT_SHUFFLE_FETCH_FAILURES machinery corrupts mapper-0 of the shuffle map 
stage, but whether the downstream reducer observes the FetchFailed (forcing the 
stage-1 recompute that inflates the raw metric) depends on task scheduling in 
the shared SparkContext, and it occasionally does not fire. Fix (test-only): 
re-run the query, resetting metrics each attempt, until the injection forces a 
recompute (stage1 > 300), up to 10 attempts, then run the original assertions. 
Does not touch the shared DAGScheduler injection machinery used by other 
suites. Validated 8x full-suite green on macos-15.



--
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