Skip to content

Fix BatchTaskUpdateRequest failures#18837

Merged
tanjialiang merged 2 commits intoprestodb:masterfrom
miaoever:fix_batchTaskUpdate
Dec 23, 2022
Merged

Fix BatchTaskUpdateRequest failures#18837
tanjialiang merged 2 commits intoprestodb:masterfrom
miaoever:fix_batchTaskUpdate

Conversation

@miaoever
Copy link
Contributor

Fixed two issues:

  1. Since BatchTaskUpdateRequest request has more specific URI pattern than the TaskUpdateRequest (/task/(.*)+/batch vs /task/(.*)+), we need to match batch request first otherwise all requests will be matched with normal TaskUpdateRequest.

  2. whether the last node of the plan is PartitionedOutputNode can't guarantee the query has shuffle stage, for example a plan with TableWriteNode can also have a PartitionedOutputNode to distribute the metadata to coordinator. Changed the check to see if serializedShuffleWriteInfo is null to tell whether it's a shuffle query or not.

@miaoever miaoever requested a review from tanjialiang December 22, 2022 21:54
@miaoever miaoever marked this pull request as ready for review December 22, 2022 21:54
@miaoever miaoever requested a review from a team as a code owner December 22, 2022 21:54
@miaoever miaoever force-pushed the fix_batchTaskUpdate branch from 575e36a to 1ea4e2e Compare December 22, 2022 21:59
Copy link
Contributor

@tanjialiang tanjialiang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks MJ good catches. Just some minor stuff.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice fix. Can we also add comments on top of this endpoint to note the importance of the ordering?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo:
havePartitionedOutputNode -> have PartitionedOutputNode

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

VELOX_CHECK_NON_NULL or VELOX_CHECK(partitionedOutputNode != nullptr)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah okay so this check is actually wrong. Good to know table write ends with an partitioned output node.

@tanjialiang
Copy link
Contributor

Oh also if you want these to be effective immediately you will also need manually create an identical diff in fbcode. Otherwise it takes a week for the changes to get in.

@miaoever miaoever force-pushed the fix_batchTaskUpdate branch 2 times, most recently from 32fe94e to ecac9c5 Compare December 22, 2022 22:29
@miaoever miaoever force-pushed the fix_batchTaskUpdate branch from ecac9c5 to 1cee0f1 Compare December 22, 2022 22:35
@tanjialiang tanjialiang merged commit 1b2f463 into prestodb:master Dec 23, 2022
@wanglinsong wanglinsong mentioned this pull request Jan 12, 2023
30 tasks
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