-
Notifications
You must be signed in to change notification settings - Fork 6k
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
[core] Minor update on task manager #49272
[core] Minor update on task manager #49272
Conversation
Signed-off-by: hjiang <hjiang@anyscale.com>
} | ||
} | ||
} | ||
if (!resubmit) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Main change here, follows best practice to early return.
@@ -304,6 +304,8 @@ std::vector<rpc::ObjectReference> TaskManager::AddPendingTask( | |||
} | |||
|
|||
bool TaskManager::ResubmitTask(const TaskID &task_id, std::vector<ObjectID> *task_deps) { | |||
RAY_CHECK(task_deps->empty()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add an assertion before emplace.
@@ -268,8 +268,9 @@ class TaskManager : public TaskFinisherInterface, public TaskResubmissionInterfa | |||
/// responsible for making sure that these dependencies become available, so | |||
/// that the resubmitted task can run. This is only populated if the task was | |||
/// not already pending and was successfully resubmitted. | |||
/// \return OK if the task was successfully resubmitted or was | |||
/// already pending, Invalid if the task spec is no longer present. | |||
/// \return true if the task was successfully resubmitted (task or actor being |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jjyao I actually have a question on how we retry and retrieve retry result, task manager only submit task, but not blocking wait their completion; task recovery manager also doesn't block wait. Is there any concern?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Discussed offline. It doesn't block, it's async operation.
Signed-off-by: hjiang <hjiang@anyscale.com>
As usual, perform some minor C++ optimization / cleanup for task manager.