-
Notifications
You must be signed in to change notification settings - Fork 480
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
[RayJob] Fix RayJob status reconciliation #1539
Merged
+91
−47
Merged
Changes from 1 commit
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
383aaf1
[RayJob]: Fix missing RayJob status update
astefanutti 12198b6
[RayJob]: Do not update RayJob ShutdownAfterJobFinishes spec field
astefanutti 456188f
[RayJob]: Set RayJob as the owner of the batch Job
astefanutti ff8ee44
[RayJob]: Avoid polling Jobs status indefinitely
astefanutti 241dfbb
[RayJob]: Reduce max job submission attempts to 3
astefanutti f7b639b
[RayJob]: Init Job status to Pending
astefanutti File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
[RayJob]: Set RayJob as the owner of the batch Job
commit 456188f4c7b5180a611dd1235bdd158b997eb24d
There are no files selected for viewing
This file contains 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
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.
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.
We might implement retry logic for RayJob in the future. If RayJob retries, it will spawn a new RayCluster and a new K8s Job. Therefore, the controller for the K8s Job should be the RayCluster.
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.
I think this will require more thoughts, depending on the evolution of the retry mechanism, and the RayCluster reuse case. Yet at the moment, as a user, I find it surprising that the Job is not cascade-deleted when I delete the RayJob.
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.
Really? It should be deleted. If not, it is a bug. RayJob is the controller reference of the RayCluster, and the RayCluster is the controller reference of the Kubernetes Job. Hence, I expected that the K8s Job should be removed if RayJob is deleted.
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.
Not in the case the RayJob does not own the RayCluster, that is when it's created with a
clusterSelector
field.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.
I conducted an experiment, and I do not observe the behavior.
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.
Got it. We do not encourage users to use that.
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.
I may deprecate it in the future.
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.
You can ignore the comment at https://github.com/ray-project/kuberay/pull/1539/files#r1365854531. I hadn't seen your reply when I wrote mine.