Skip to content

[serve] haproxy grpc#63735

Draft
akyang-anyscale wants to merge 16 commits into
ray-project:masterfrom
akyang-anyscale:hap-ga-1
Draft

[serve] haproxy grpc#63735
akyang-anyscale wants to merge 16 commits into
ray-project:masterfrom
akyang-anyscale:hap-ga-1

Conversation

@akyang-anyscale

Copy link
Copy Markdown
Contributor

Thank you for contributing to Ray! 🚀
Please review the Ray Contribution Guide before opening a pull request.

⚠️ Remove these instructions before submitting your PR.

💡 Tip: Mark as draft if you want early feedback, or ready for review when it's complete.

Description

Briefly describe what this PR accomplishes and why it's needed.

Related issues

Link related issues: "Fixes #1234", "Closes #1234", or "Related to #1234".

Additional information

Optional: Add implementation details, API changes, usage examples, screenshots, etc.

support for haproxy grpc

known limitations:
* streaming (to be implemented)
* metrics (to be implemented)
* healthz response is changed such that the response object is None. The
message is in the grpc call details instead of the response now (because
of haproxy limitations). The status code is unchanged (still `OK` on
healthy and `UNAVAILABLE` otherwise).
* ListApplications request is forwarded to the serve proxy, so it does
not work if serve proxy is down.

---------

Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Make haproxy http2 tuning parameters adjustable via env var

---------

Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request introduces gRPC support for HAProxy in Ray Serve, adding HTTP/2 tuning flags, a gRPC frontend, and health check configurations. Feedback on the changes highlights three key improvements: adding the missing check parameter to gRPC backend servers to enable active health checking, handling empty backend scenarios in the gRPC healthz template to avoid confusing NOT_FOUND errors, and initializing self._grpc_fallback_target in __init__ to prevent potential AttributeErrors.

Comment thread python/ray/serve/_private/haproxy_templates.py
Comment thread python/ray/serve/_private/haproxy_templates.py
Comment thread python/ray/serve/_private/haproxy.py
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
@akyang-anyscale akyang-anyscale added the go add ONLY when ready to merge, run all tests label Jun 2, 2026
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Signed-off-by: akyang-anyscale <alexyang@anyscale.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

go add ONLY when ready to merge, run all tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Ray fails to serialize self-reference objects

1 participant