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

Unblock driver when one of the operator finishes #13616

Merged
merged 2 commits into from
Aug 12, 2022

Conversation

sopel39
Copy link
Member

@sopel39 sopel39 commented Aug 11, 2022

Description

As described in https://github.com/trinodb/trino/issues/4065
highly selective limit queries might not finish when
required number of rows is produced. This is due to the
case described in https://github.com/prestodb/presto/issues/9357.
This problem is solved by allowing LocalExchangeSinkOperator to
notify driver when operator becomes finished.

Is this change a fix, improvement, new feature, refactoring, or other?

improvment

Is this a change to the core query engine, a connector, client library, or the SPI interfaces? (be specific)

core engine

How would you describe this change to a non-technical end user or system administrator?

Highly selective LIMIT queries will finish as soon as required number of rows is processed

Related issues, pull requests, and links

Fixes #4065

Documentation

( ) No documentation is needed.
( ) Sufficient documentation is included in this PR.
( ) Documentation PR is available with #prnumber.
( ) Documentation issue #issuenumber is filed, and can be handled later.

Release notes

( ) No release notes entries required.
( ) Release notes entries required with the following suggested text:

# Section
* Make highly selective queries finish as soon as required number of rows is produced ({issue}`issuenumber`)

@sopel39
Copy link
Member Author

sopel39 commented Aug 12, 2022

Failed due #13658

As described in trinodb#4065
highly selective limit queries might not finish when
required number of rows is produced. This is due to the
case described in prestodb/presto#9357.
This problem is solved by allowing LocalExchangeSinkOperator to
notify driver when operator becomes finished.
@sopel39 sopel39 merged commit 33ad5ec into trinodb:master Aug 12, 2022
@sopel39 sopel39 deleted the ks/unblock branch August 12, 2022 19:37
@sopel39 sopel39 mentioned this pull request Aug 12, 2022
@github-actions github-actions bot added this to the 393 milestone Aug 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

Highly selective LIMIT queries don't complete as soon as required data is output
2 participants