[Rust][Arrow] Coordinate explicit close with recovery - #677
Open
teodordelibasic-db wants to merge 2 commits into
Open
[Rust][Arrow] Coordinate explicit close with recovery#677teodordelibasic-db wants to merge 2 commits into
teodordelibasic-db wants to merge 2 commits into
Conversation
Signed-off-by: teodordelibasic-db <teodor.delibasic@databricks.com>
Signed-off-by: teodordelibasic-db <teodor.delibasic@databricks.com>
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.
What changes are proposed in this pull request?
Arrow explicit close previously began supervisor teardown only after its flush attempt completed. If the supervisor was recovering, backoff, connection setup, ready-signal waiting, authentication invalidation, or replay could therefore continue until a separate timeout resolved that phase.
This PR coordinates close and recovery through one level-triggered close state and one supervisor-owned finalization path.
Intentionally deferred
No public API, FFI signature, or ABI changes are introduced.
How is this tested?
test_close_interrupts_recovery_backoff: close interrupts a parked recovery backoff and preserves the triggering error.test_close_interrupts_reconnect_do_put_handshake: close cancels a blocked reconnect DoPut handshake.test_close_interrupts_reconnect_ready_wait: close cancels reconnect ready-signal waiting.test_close_preserves_reconnect_auth_rejection: a reconnect authentication rejection wins over the older transport failure and remains stable across repeated close calls.test_close_during_partial_replay_retains_exact_unacked_suffixes: close during partial replay retains only the durable-watermark suffix and later pending batches.ready_process_error_wins_over_visible_flush_completion: a ready peer error is processed before a simultaneous close-flush completion.ready_ack_work_is_polled_before_visible_flush_completion: ready ACK work is processed before a simultaneous close-flush completion.ready_reconnect_result_wins_over_ready_close_request: a completed reconnect result is not discarded when close becomes ready at the same time.empty_close_target_does_not_mask_terminal_error: closing an empty stream preserves its terminal error.explicit_close_cancellation_finalizes_before_close_publication: a private close cancellation preserves the original recovery error before close-state publication becomes visible.Fixes #657.