Skip to content
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

[RayService] Avoid sending health check requests to the head Pod when excludeHeadPodFromServeSvc is true #2776

Merged
merged 1 commit into from
Jan 20, 2025

Conversation

kevin85421
Copy link
Member

Why are these changes needed?

Related issue number

Checks

  • I've made sure the tests are passing.
  • Testing Strategy
    • Unit tests
    • Manual tests
    • This PR is not tested :(

Signed-off-by: kaihsun <[email protected]>
@@ -121,7 +120,6 @@ func (r *RayServiceReconciler) Reconcile(ctx context.Context, request ctrl.Reque
originalRayServiceInstance := rayServiceInstance.DeepCopy()

if err := validateRayServiceSpec(rayServiceInstance); err != nil {
logger.Error(err, "The RayService spec is invalid")
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error will be returned in Reconcile, so controller runtime will handle it. No need to print it.
Screenshot 2025-01-19 at 11 07 26 PM

@@ -1135,8 +1133,6 @@ func (r *RayServiceReconciler) reconcileServe(ctx context.Context, rayServiceIns
}
}

// TODO(architkulkarni): Check the RayVersion. If < 2.8.0, error.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No one has complained about it for years. Remove the TODO.

@@ -1183,29 +1183,29 @@ func (r *RayServiceReconciler) labelHeadPodForServeStatus(ctx context.Context, r
return fmt.Errorf("found 0 head. cluster name %s, namespace %v", rayClusterInstance.Name, rayClusterInstance.Namespace)
}

httpProxyClient := r.httpProxyClientFunc()
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

httpProxy is not very precise.

for key, value := range headPod.Labels {
originalLabels[key] = value
}
if err = httpProxyClient.CheckProxyActorHealth(ctx); err == nil && !excludeHeadPodFromServeSvc {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If excludeHeadPodFromServeSvc is true, we don't need to send health check requests to the head Pod.

@kevin85421
Copy link
Member Author

cc @rueian

@kevin85421 kevin85421 marked this pull request as ready for review January 20, 2025 09:14
@kevin85421 kevin85421 merged commit f932962 into ray-project:master Jan 20, 2025
24 checks passed
win5923 pushed a commit to win5923/kuberay that referenced this pull request Jan 20, 2025
win5923 pushed a commit to win5923/kuberay that referenced this pull request Jan 20, 2025
@kevin85421 kevin85421 mentioned this pull request Jan 21, 2025
48 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants