[SDK Sentinel] Stabilize Nexus abandon cancellation test - #3043
Open
sdk-sentinel-bot wants to merge 1 commit into
Open
Conversation
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.
Caution
This PR contains untrusted AI-generated code. Do not approve or run CI until a maintainer has reviewed the diff. SDK Sentinel verified that GitHub Actions remained approval-gated with zero executable jobs when this PR was opened.
Summary
Stabilize the Nexus ABANDON cancellation test after a [captured Java 23 in-memory failure](https://github.com/temporalio/sdk-java/actions/runs/33014790590). The bounded window contains no preceding equivalent target-branch success.
Root cause
The test runs immediate-cancel and after-start scenarios sequentially using shared static signals. Clearing those signals between phases is racy because the first handler can publish after the clear, making the second phase appear complete.
Fix
Give the immediate-cancel path a zero-delay handler that cannot publish the completion signal, and publish the operation-started signal only from the after-start path. This removes cross-phase writers without sleeps, retries, or weakened assertions.
Validation
The pre-change test did not fail in one local execution. After the change, the focused method passed five times and the full cancellation class passed. The fixed repository validator passed in a writable mirror; its target-checkout attempt was blocked by read-only Git submodule metadata. Java 23 in-memory and Java 11 CLI CI remain required.
Validation status:
validation-incompletehighmediummediumstandard— 1 changed file; 1.9 KiBnot-reproduced— One pre-change focused execution passed; earlier setup attempts were blocked before test execution by preloaded-output permissions and an unavailable optional offline dependency.pass-after-only— The existing ABANDON regression test was made deterministic and passed five focused repetitions; the full cancellation class also passed.Gradle formatting and test-source compilation) — passedGradle formatting and test-source compilation) — did not pass (failure)Investigator-run checks
./gradlew --offline --no-daemon :temporal-sdk:cleanTest :temporal-sdk:test --tests 'io.temporal.workflow.nexus.CancelWorkflowAsyncOperationTest.cancelAsyncOperationAbandon' -x :temporal-sdk:compileJava17Java— passed; 5 attempt(s). All five post-change repetitions passed in the writable /tmp mirror../gradlew --offline --no-daemon :temporal-sdk:cleanTest :temporal-sdk:test --tests 'io.temporal.workflow.nexus.CancelWorkflowAsyncOperationTest' -x :temporal-sdk:compileJava17Java— passed; 1 attempt(s). The complete cancellation test class passed..ci-flake-runtime/input/validate.sh— failed; 1 attempt(s). The target-checkout attempt passed formatting through temporal-sdk, then the submodule update task could not write read-only .git metadata.GRADLE_USER_HOME=/tmp/sdk-sentinel-gradle-home /home/runner/work/sdk-sentinel/sdk-sentinel/target/.ci-flake-runtime/input/validate.sh— passed; 1 attempt(s). The fixed validator passed in 1m24s against the candidate's writable /tmp mirror.Required target CI
Residual risks
Automation provenance
d730cff553b264f104eaa1f40c0ecd8ce2df775dIf this finding should not be fixed, apply the
sdk-sentinel:false-positivelabel and close the PR. Sentinel will suppress the finding until its affected source changes.SDK Sentinel recurrence history
2026-08-26 21:27 UTC2026-08-26 21:27 UTC