Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SPARK-51429][Connect] Add "Acknowledgement" message to ExecutePlanResponse #50193

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

vicennial
Copy link
Contributor

What changes were proposed in this pull request?

Adds an Acknowledgement message in ExecutePlanResponse which is essentially an empty response containing metadata from the server. The message is sent by the server back to the client as the first message (one-time) on any ExecutePlan or ReattachExecute requests.

Why are the changes needed?

An acknowledgement allows a client to disconnect right after registering the request without waiting for its full processing.
It is especially useful when the server supports reattachment or otherwise, can be used for early termination if the client detects a delay in registration by the server.

Does this PR introduce any user-facing change?

Yes.
The first message in the response stream of ExecutePlan/ReattachExecute will be an ExecutePlanResponse containing the Acknowledgement message.

Note: This is a no-op for users not interacting with ExecutePlanResponse directly (e.g. Using df.collect()) or those who are already filtering messages for those containing a specific field.

How was this patch tested?

New + existing unit tests.

Was this patch authored or co-authored using generative AI tooling?

No.

@github-actions github-actions bot added the PYTHON label Mar 7, 2025
@vicennial
Copy link
Contributor Author

Putting this on hold ATM as some unexpected complications popped up (particularly the interactions with response indices and response caching)

@vicennial vicennial marked this pull request as draft March 8, 2025 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants