Skip to content

ADBDEV-7617: Fix query cancelation #173

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

Draft
wants to merge 1 commit into
base: pxf-6.x
Choose a base branch
from
Draft

Conversation

KnightMurloc
Copy link

@KnightMurloc KnightMurloc commented Jun 27, 2025

In some circumstances, such as the unavailability of a remote server, we may be
stuck for a long time in the finish_upload function. This happened because we
are waiting for all connections to be closed. For this, we call
the curl_multi_perform function. Since there is nothing to receive or send, it
immediately exits, while informing us that we still have open connections. After
that, we will stay in this loop until PXF reports an error on timeout. During
this loop, we cannot cancel the query because there is no CHECK_FOR_INTERRUPTS
call in the loop. This patch adds CHECK_FOR_INTERRUPTS to the connection
completion waiting loop so that if we stay in this loop for a long time, the
query can be canceled.

In some circumstances, such as the unavailability of a remote server, we may be
stuck for a long time in the finish_upload function. This happened because we
are waiting for all connections to be closed. For this, we call the
curl_multi_perform function. Since there is nothing to receive or send, it
immediately exits, while informing us that we still have open connections. After
that, we will stay in this loop until PXF reports an error on timeout. During
this loop, we cannot cancel the request because there is no CHECK_FOR_INTERRUPTS
call in the loop.
This patch adds CHECK_FOR_INTERRUPTS to the connection completion waiting loop
so that if we stay in this loop for a long time, the query can be canceled.
@BenderArenadata
Copy link

Allure report https://allure.dev.adsw.io/launch/105465

@KnightMurloc KnightMurloc marked this pull request as draft June 27, 2025 12:34
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.

2 participants