mirror of
https://github.com/wassname/ray.git
synced 2026-07-05 21:07:06 +08:00
Avoid fate sharing with owner for detached actors (#8267)
This commit is contained in:
@@ -6,9 +6,6 @@ import pytest
|
||||
import ray
|
||||
from ray import serve
|
||||
|
||||
# TODO(edoakes): the failure tests currently fail with the GCS service enabled.
|
||||
os.environ["RAY_GCS_SERVICE_ENABLED"] = "false"
|
||||
|
||||
if os.environ.get("RAY_SERVE_INTENTIONALLY_CRASH", False):
|
||||
serve.master._CRASH_AFTER_CHECKPOINT_PROBABILITY = 0.5
|
||||
|
||||
|
||||
@@ -2514,9 +2514,9 @@ void NodeManager::AssignTask(const std::shared_ptr<Worker> &worker, const Task &
|
||||
: worker->GetTaskResourceIds());
|
||||
|
||||
// If the owner has died since this task was queued, cancel the task by
|
||||
// killing the worker.
|
||||
if (failed_workers_cache_.count(owner_worker_id) > 0 ||
|
||||
failed_nodes_cache_.count(owner_node_id) > 0) {
|
||||
// killing the worker (unless this task is for a detached actor).
|
||||
if (!worker->IsDetachedActor() && (failed_workers_cache_.count(owner_worker_id) > 0 ||
|
||||
failed_nodes_cache_.count(owner_node_id) > 0)) {
|
||||
// TODO(swang): Skip assigning this task to this worker instead of
|
||||
// killing the worker?
|
||||
KillWorker(worker);
|
||||
|
||||
Reference in New Issue
Block a user