Spark: Bound runaway serializable-isolation and concurrent-refresh tests - #16562
Open
wombatu-kun wants to merge 1 commit into
Open
Spark: Bound runaway serializable-isolation and concurrent-refresh tests#16562wombatu-kun wants to merge 1 commit into
wombatu-kun wants to merge 1 commit into
Conversation
wombatu-kun
force-pushed
the
issue/16359-bound-runaway-concurrency-tests
branch
from
June 4, 2026 06:51
600b18b to
e27bc6b
Compare
|
This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 1 week if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the dev@iceberg.apache.org list. Thank you for your contributions. |
Contributor
Author
|
not stale |
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
wombatu-kun
force-pushed
the
issue/16359-bound-runaway-concurrency-tests
branch
from
August 4, 2026 02:43
e27bc6b to
4d37239
Compare
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.
Closes #16359
Summary
Several
spark-extensionsconcurrency tests ran two worker threads in a barrier-synchronized loop bounded byInteger.MAX_VALUEwhile the main thread blocked onassertThatThrownBy(<op>Future::get)with no timeout, expecting a conflict exception. When that exception was never thrown, nothing bounded either thread — the append thread kept committing data files until CI hit its wall-clock limit or ran out of disk (as in #16303, where the runaway filled the GitHub Actions disk and was retriggered several times before the cause was found). This makes those tests fail fast instead of relying on external limits.What changed
MAX_OPERATIONS = 20constant — the same value the sibling*WithSnapshotIsolationtests already use with this identical harness — so the loop can no longer run unbounded.Future.get(OPERATION_TIMEOUT_MINUTES, TimeUnit.MINUTES)(5 minutes) and cancelled the operation future infinally, so a stuck operation is interrupted and the wait can't block forever.MAX_OPERATIONSandOPERATION_TIMEOUT_MINUTESintoSparkRowLevelOperationsTestBaseso these concurrency tests share one bound (the snapshot-isolation siblings now reference the same constant).Affected methods in
spark/v4.1:testMergeWithSerializableIsolation,testDeleteWithSerializableIsolation,testUpdateWithSerializableIsolation. The copy-on-writetestMergeWithConcurrentTableRefresh,testDeleteWithConcurrentTableRefreshandtestUpdateWithConcurrentTableRefreshexist only inspark/v3.5andspark/v4.0, so they are covered by the follow-up backport PR rather than here.In a passing run the conflict still fires within the first couple of iterations, so behavior is unchanged; in a regression the bounded loop plus timeout make the test fail fast with a clear assertion instead of exhausting CI resources.
AI Disclosure