-
Notifications
You must be signed in to change notification settings - Fork 16k
refactor: only access memory coordinator interface from browser process #31295
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
If I understand this change correctly, memory info is now going to be retrieved from the browser process, instead of the renderer process. Is this expected to degrade the response time of this API, then? (I want to use this API, but will call it many times per second so am sensitive to its performance) |
@pushkin- every child process including the browser registers itself as a client with the resource coordinator service that lives inside the browser process, the coordinator is interface that can be used to talk with the clients to get respective memory dumps. At the end of day, the clients are responsible to collect the dumps and send them to the coordinator. This PR only changes the point of access to the coordinator interface, even before this PR accessing the coordinator from the renderer causes it talk to the browser process via mojo to get the interface. With this PR it makes it clear where the coordinator lives and there is no behavior change. |
No Release Notes |
I was unable to backport this PR to "12-x-y" cleanly; |
I was unable to backport this PR to "13-x-y" cleanly; |
I was unable to backport this PR to "14-x-y" cleanly; |
I was unable to backport this PR to "15-x-y" cleanly; |
@deepak1556 has manually backported this PR to "13-x-y", please check out #31305 |
…ss (#31305) * refactor: only access memory coordinator interface from browser process (#31295) Refs https://chromium-review.googlesource.com/c/chromium/src/+/3174305 * chore: fix build * chore: fix lint
Description of Change
As part of the issue https://bugs.chromium.org/p/chromium/issues/detail?id=1251787 chromium refactored the memory coordinator interface to be only accessed from the browser process.
Refs https://chromium-review.googlesource.com/c/chromium/src/+/3174305
Currently implementation of
process.getProcessMemoryInfo
accesses the coordinator directly from the renderer process. This PR refactors the internal implementation to accommodate the upstream change while maintaining the user facing api and does not introduce any behavior changes.Required for landing these security backports
/cc @ppontes
Checklist
npm test
passesRelease Notes
Notes: none