-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Remove CPU profiler from Ray Service Replica, Proxy & Controller #54438
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
base: master
Are you sure you want to change the base?
Conversation
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.
Pull Request Overview
This PR removes unused CPU profiling code from the Ray Serve replica, proxy, and controller components.
- Eliminates
configure_component_cpu_profiler
imports and initializations. - Deletes the
_save_cpu_profile_data
methods. - Removes the now-unneeded
marshal
import.
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
File | Description |
---|---|
python/ray/serve/_private/replica.py | Removed CPU profiler import, initialization, and save method |
python/ray/serve/_private/proxy.py | Removed CPU profiler import, initialization, and save method |
python/ray/serve/_private/controller.py | Removed marshal import, CPU profiler import, initialization, and save method |
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.
Ok to remove profiling from all replica/controller/proxy since I don't think its part of anyones workflow.
But I want to also note that the reported issue is only with replica; proxy and controller cpu profiler should be correctly.
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.
if we're removing all usage then let's also remove configure_component_cpu_profiler
and RAY_SERVE_ENABLE_CPU_PROFILING
Why are these changes needed?
The method
ray.serve._private.replica.ReplicaActor._save_cpu_profile_data
accesses two non-existent instance attributes,self.cpu_profiler
andself.cpu_profiler_log
. This PR removes the method and the associated variables as there is no usage.They can be added back by referencing git history.
Related issue number
Closes #53677
Checks
git commit -s
) in this PR.scripts/format.sh
to lint the changes in this PR.method in Tune, I've added it in
doc/source/tune/api/
under thecorresponding
.rst
file.