Skip to content

[Cherry-pick to branch-1.3] [#13420] fix(core): Fix flaky TestJobManagerMultiNode.testCancelJobFromAnotherNode (#13460) - #13879

Merged
yuqi1129 merged 1 commit into
apache:branch-1.3from
yuqi1129:cherry-pick-13460-branch-1.3
Oct 15, 2026
Merged

yuqi1129 merged 1 commit into
apache:branch-1.3from
yuqi1129:cherry-pick-13460-branch-1.3

Conversation

@yuqi1129

Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

Cherry-pick #13460 to branch-1.3. After node A's first status pull, accept either CANCELLING or CANCELLED as the stored status. The final assertions after the second pull (CANCELLED and finishedAt > 0) are unchanged.

Why are the changes needed?

cancelOwnedJob cancels the job and immediately reads its status back. If the local process exits before the read, the first pull already stores CANCELLED, so the test fails depending on timing. The flake still occurs on branch-1.3.

Fix: #13420

Does this PR introduce any user-facing change?

No.

How was this patch tested?

./gradlew :core:test --tests TestJobManagerMultiNode -PskipITs (9 passed).

…lJobFromAnotherNode (apache#13460)

### What changes were proposed in this pull request?

After node A's first status pull, accept either `CANCELLING` or
`CANCELLED` as the stored status. The final assertions after the second
pull (`CANCELLED` and `finishedAt > 0`) are unchanged.

### Why are the changes needed?

`cancelOwnedJob` cancels the job and immediately reads its status back.
If the local process exits before the read, the first pull already
stores `CANCELLED`, so the test fails depending on timing.

Fix: apache#13420

### Does this PR introduce _any_ user-facing change?

No.

### How was this patch tested?

`./gradlew :core:test --tests TestJobManagerMultiNode -PskipITs`

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Qi Yu <yuqi@datastrato.com>
(cherry picked from commit c384d03)
Copilot AI balanced review requested due to automatic review settings October 15, 2026 09:26

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@github-actions

Copy link
Copy Markdown

Code Coverage Report

Overall Project 69.1% 🟢
Files changed No Java source files changed -

Module Coverage
aliyun 19.74% 🔴
api 47.62% 🟢
authorization-common 85.96% 🟢
authorization-ranger 10.17% 🔴
aws 53.54% 🟢
aws-bundle 0.0% 🔴
azure 32.1% 🔴
azure-bundle 0.0% 🔴
catalog-common 19.13% 🔴
catalog-fileset 80.73% 🟢
catalog-glue 71.33% 🟢
catalog-hive 80.55% 🟢
catalog-jdbc-clickhouse 84.7% 🟢
catalog-jdbc-common 51.06% 🟢
catalog-jdbc-doris 83.12% 🟢
catalog-jdbc-hologres 54.03% 🟢
catalog-jdbc-mysql 81.8% 🟢
catalog-jdbc-oceanbase 78.6% 🟢
catalog-jdbc-postgresql 83.89% 🟢
catalog-jdbc-starrocks 79.16% 🟢
catalog-kafka 75.49% 🟢
catalog-lakehouse-generic 61.21% 🟢
catalog-lakehouse-hudi 79.1% 🟢
catalog-lakehouse-iceberg 85.9% 🟢
catalog-lakehouse-paimon 82.17% 🟢
catalog-model 77.99% 🟢
cli 44.51% 🟢
client-java 78.31% 🟢
client-java-runtime 0.0% 🔴
common 51.08% 🟢
core 83.8% 🟢
filesystem-hadoop3 77.68% 🟢
flink 18.07% 🔴
flink-common 50.82% 🟢
flink-runtime 0.0% 🔴
gcp 32.2% 🔴
hadoop-common 15.43% 🔴
hive-metastore-common 62.61% 🟢
hive-metastore3-libs 58.8% 🟢
iceberg-aliyun-bundle 0.0% 🔴
iceberg-common 60.39% 🟢
iceberg-rest-server 75.24% 🟢
idp-basic 86.79% 🟢
integration-test-common 0.0% 🔴
jobs 60.37% 🟢
lance-common 29.23% 🔴
lance-rest-server 60.7% 🟢
lineage 59.39% 🟢
optimizer 82.92% 🟢
optimizer-api 42.56% 🟢
server 89.65% 🟢
server-common 78.61% 🟢
spark 28.57% 🔴
spark-common 48.61% 🟢
trino-connector 62.84% 🟢

@yuqi1129
yuqi1129 merged commit 86df9e4 into apache:branch-1.3 Oct 15, 2026
35 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants