Add termination time to TaskStats#7479
Closed
kevinwilfong wants to merge 1 commit intofacebookincubator:mainfrom
Closed
Add termination time to TaskStats#7479kevinwilfong wants to merge 1 commit intofacebookincubator:mainfrom
kevinwilfong wants to merge 1 commit intofacebookincubator:mainfrom
Conversation
Summary: Like the title says, store termination time, separately from execution end time, in the TaskStats. The reason for needing termination time comes from Presto. They currently use execution end time to determine when a task was last used and clean up the Task once it's terminated and after some threshold of time after the end time. If a task has partitioned output, that output may not be fully consumed until some time after the execution end time. Termination time is guaranteed to be after the partitioned output has been consumed (assuming the query is running successfully), and so it's a better reflection of how long ago the task was used. Today we see that for some queries, the execution end time is long before the termination time, and so Presto will delete the task as soon as it's terminated. This leads to issues with in flight status checks Presto makes against the Worker. Differential Revision: D51140307
✅ Deploy Preview for meta-velox canceled.
|
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D51140307 |
xiaoxmeng
reviewed
Nov 9, 2023
Contributor
xiaoxmeng
left a comment
There was a problem hiding this comment.
@kevinwilfong thanks for the change!
| if (taskStats_.executionEndTimeMs == 0) { | ||
| taskStats_.executionEndTimeMs = getCurrentTimeMs(); | ||
| } | ||
| if (taskStats_.terminationTimeMs == 0) { |
Contributor
There was a problem hiding this comment.
Can we add unit test for this new timestamp? thanks!
Contributor
|
This pull request has been merged in 8ff8d7a. |
|
Conbench analyzed the 1 benchmark run on commit There were no benchmark performance regressions. 🎉 The full Conbench report has more details. |
kevinwilfong
added a commit
to kevinwilfong/presto
that referenced
this pull request
Nov 9, 2023
To pull in facebookincubator/velox#7479 which we can use to address some errors we've been seeing when the Coordinator gets the status from the Worker.
amitkdutta
pushed a commit
to prestodb/presto
that referenced
this pull request
Nov 10, 2023
To pull in facebookincubator/velox#7479 which we can use to address some errors we've been seeing when the Coordinator gets the status from the Worker.
wypb
pushed a commit
to wypb/presto
that referenced
this pull request
Dec 22, 2023
To pull in facebookincubator/velox#7479 which we can use to address some errors we've been seeing when the Coordinator gets the status from the Worker.
kaikalur
pushed a commit
to kaikalur/presto
that referenced
this pull request
Mar 14, 2024
To pull in facebookincubator/velox#7479 which we can use to address some errors we've been seeing when the Coordinator gets the status from the Worker.
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.
Summary:
Like the title says, store termination time, separately from execution end time, in the TaskStats.
The reason for needing termination time comes from Presto. They currently use execution end time to determine when a task was last used and clean up the Task once it's terminated and after some threshold of time after the end time. If a task has partitioned output, that output may not be fully consumed until some time after the execution end time. Termination time is guaranteed to be after the partitioned output has been consumed (assuming the query is running successfully), and so it's a better reflection of how long ago the task was used.
Today we see that for some queries, the execution end time is long before the termination time, and so Presto will delete the task as soon as it's terminated. This leads to issues with in flight status checks Presto makes against the Worker.
Differential Revision: D51140307