-
Notifications
You must be signed in to change notification settings - Fork 55
Get render process information from ICoreWebView2 object #3298
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
Comments
@ztextplus - |
Hi @ztextplus , does andy's reply above solve the problem? If yes can the issue be closed? |
@aluhrs13 @novac42 Why is there such a requirement? We want to count the memory and CPU usage of featrue1 and featrue2 respectively. |
@ztextplus can you check out #3234? That is in-progress and might fit your need. |
Hi, @ztextplus can you explain more about feature1/feature2? Are they created from same ICoreWebView2 with child
FYI, |
@aluhrs13 @novac42 @JosephJin0815 Among the four render processes, which are created by the browser corresponding to feature 1 and which are created by the browser corresponding to feature 2 Using GetProcessInfos, you can get all process IDs, but you cannot get the corresponding relationship between feature1 and Render processes. At present, the way I can think of is to kill a render. At this time, if feature1 does not display normally, I know that the render I just killed corresponds to feature1. |
I don't think this API support your case. There're different cases one browser have many renderer process. This api will support only iframe case, which you create iframes inside that main page, and then you can get renderer process id for that main page(ICoreWebView2) and iframe(ICoreWebView2Frame). See code example in spec review #3234 for more details. |
@novac42 @JosephJin0815 @aluhrs13 In actual use, we will find that the CPU and Memory usage of a certain render process is very high, and we really want to locate which feature this rendering process corresponds to. If this API can be provided, it will be very convenient for us to locate the problem. |
@ztextplus Sorry for the wait. Right now we don't have this feature, I've added it to our backlog and will evaluate the priority in grooming. |
I have same issue, and the workroud mentioned above is for C#, how does it work on C++ @novac42 |
Hi @ztextplus, And each Also a reference about Process model for WebView2 apps |
@dfghj44444 Do you mean |
@JosephJin0815 In fact I want to get all render process ids(including the main frame and all sub-iframes) which belong to a web-page, thus I could calc the cpu and memory usage of a web-page. |
Hi @dfghj44444 |
Is your feature request related to a problem? Please describe.
We have multiple features that use the browser function, and now we really want to have such a requirement.
We want to count the CPU and Memory usage of each feature, that is, count the CPU and Memory usage of a certain feature for the Render process. So I hope that Webview2 can provide an interface to get the corresponding set of Render process IDs from the ICoreWebView2 object.
If this interface is provided, the usage process is as follows:
GetRenderProsses
provided by ICoreWebView2 object.GetRenderProsses
.Although Webview2 provides the
GetProcessInfos
interface, this interface obtains all the process information related to Webview2, we still cannot know the Render process information corresponding to an ICoreWebView2.AB#44641334
The text was updated successfully, but these errors were encountered: