Repository navigation
[Core] allow worker lazily bind to job_id - #30883
Merged
Merged
Conversation
scv119
force-pushed
the
context-refactor
branch
from
December 5, 2022 07:05
f9424d0 to
0b09e62
Compare
scv119
marked this pull request as ready for review
December 5, 2022 18:26
Contributor
|
Lmk when this is not WIP anymore! |
Contributor
Author
|
ah this run_on_all_workers is annoying |
scv119
force-pushed
the
context-refactor
branch
from
January 1, 2023 05:22
1fd6dff to
ef26a0c
Compare
Signed-off-by: Antoni Baum <[email protected]>
Yard1
requested review from
a team,
Yard1,
amogkam,
krfricke,
matthewdeng,
maxpumperla,
richardliaw and
xwjiang2010
as code owners
January 20, 2023 22:59
matthewdeng
approved these changes
Jan 20, 2023
cadedaniel
approved these changes
Jan 20, 2023
scv119
force-pushed
the
context-refactor
branch
from
January 21, 2023 01:52
a50b2a1 to
8167b10
Compare
scv119
added a commit
that referenced
this pull request
Jan 22, 2023
… disable run_on_all_workers flaky tests (#31836) Why are these changes needed? #30883 we changed the behavior of first driver connect to a raylet: previously the driver connection will wait for the prestarted workers to connect before returns, and after #30883 it no longer does so. This has caused some test flakiness for test_failure_4.py -k test_task_crash_after_raylet_dead_throws_node_died_error and test_ray_shutdown.py -k test_driver_dead We restore the previous behavior and fixes the test flakiness. Also #30883 added flakiness for run_functions_on_all_workers. we disable those flaky tests
andreapiso
pushed a commit
to andreapiso/ray
that referenced
this pull request
Jan 22, 2023
…oject#31772) Why are these changes needed? In ray-project#30883 we lazy bind job_config to a worker. In this way we can no longer know the job id when worker starts up. Instead, we log the job_id as part of the log similar to task_name, and parse it when we process the log. To remain backward compatibility, we don't remove job_id from the worker log for now; but we probably will remove it in the future version. Signed-off-by: Andrea Pisoni <[email protected]>
andreapiso
pushed a commit
to andreapiso/ray
that referenced
this pull request
Jan 22, 2023
Why are these changes needed? This PR enables worker lazy binding to job_ids. This enables us to pre-start job agnostic cpu workers in the follow up PRs. The main changes in this PR: change the worker side context (WorkerContext) to allow lazy binding to job_id. update the raylet side context (Worker) to allow lazy binding to job_id. change worker_pool to prestart workers without id specified. it also fixed a bug to where the runtime_env_hash is not set when prestart workers. Signed-off-by: Chen Shen <[email protected]> Signed-off-by: Antoni Baum <[email protected]> Co-authored-by: Antoni Baum <[email protected]> Signed-off-by: Andrea Pisoni <[email protected]>
andreapiso
pushed a commit
to andreapiso/ray
that referenced
this pull request
Jan 22, 2023
… disable run_on_all_workers flaky tests (ray-project#31836) Why are these changes needed? ray-project#30883 we changed the behavior of first driver connect to a raylet: previously the driver connection will wait for the prestarted workers to connect before returns, and after ray-project#30883 it no longer does so. This has caused some test flakiness for test_failure_4.py -k test_task_crash_after_raylet_dead_throws_node_died_error and test_ray_shutdown.py -k test_driver_dead We restore the previous behavior and fixes the test flakiness. Also ray-project#30883 added flakiness for run_functions_on_all_workers. we disable those flaky tests Signed-off-by: Andrea Pisoni <[email protected]>
scv119
added a commit
that referenced
this pull request
Jan 22, 2023
…rs and reenable test (#31838) run_function_on_all_workers importing requires job_id to run properly. after #30883 the worker might not have job_id when startup, which lead to run_function_on_all_workers failed to be executed on start up. to fix it, we defer the import_thread start up until job_config is initialized.
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.
Why are these changes needed?
This PR enables worker lazy binding to job_ids. This enables us to pre-start job agnostic cpu workers in the follow up PRs.
The main changes in this PR:
it also fixed a bug to where the runtime_env_hash is not set when prestart workers.
TBD: run release tests
Related issue number
Checks
git commit -s) in this PR.scripts/format.shto lint the changes in this PR.