-
Notifications
You must be signed in to change notification settings - Fork 7.1k
[4/n] remove env var - ray serve proxy always on head node #59963
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
Conversation
Signed-off-by: harshit <[email protected]>
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
abrarsheikh
left a comment
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.
lg2m. @akyang-anyscale please review
Signed-off-by: harshit <[email protected]>
Signed-off-by: harshit <[email protected]>
Signed-off-by: harshit <[email protected]>
…roject/ray into remove-env-var-always-on-head-node
Signed-off-by: harshit <[email protected]>
…roject/ray into remove-env-var-always-on-head-node
akyang-anyscale
left a comment
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.
lgtm. looks like you may need to update the tests to pass in the head node id on .update(...)
Signed-off-by: harshit <[email protected]>
Signed-off-by: harshit <[email protected]>
done, fixed it. |
Summary
This PR removes the
RAY_SERVE_ALWAYS_RUN_PROXY_ON_HEAD_NODEenvironment variable as it has no practical effect in production.Why this env var is redundant
The env var was intended to "always run a proxy on the head node even if it has no replicas." However, the controller already unconditionally ensures the head node is included in the proxy nodes set, making this flag ineffective.
Code flow analysis
In
controller.py_update_proxy_nodes()(lines 419-430):The head node (
_controller_node_id) is always added to_proxy_nodesunconditionally.In
proxy_state.pyupdate()(where the env var was checked):This check happens after the controller already added the head node. Since proxy_nodes is a set, adding the same node again is a no-op.
Consequence
RAY_SERVE_ALWAYS_RUN_PROXY_ON_HEAD_NODE=0had no effect because the controller adds the head node regardless.RAY_SERVE_ALWAYS_RUN_PROXY_ON_HEAD_NODE=1(the default) was also a no-op since the head node was already present.Changes
RAY_SERVE_ALWAYS_RUN_PROXY_ON_HEAD_NODEdefinition fromconstants.pyproxy_state.py