-
Notifications
You must be signed in to change notification settings - Fork 508
8244579: Windows "User Objects" leakage with WebView #229
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
👋 Welcome back ajoseph! A progress list of the required criteria for merging this PR into |
/reviewers 2 |
@kevinrushforth |
Is there a way to create a test? |
I think it will be difficult to write a test for this. While debugging, RunLoop was mostly used by threads managing heap. It can't be directly accessed via JavaScript. Also, this issue only affects Windows. The best way would be to monitor the user objects created. |
https://bugs.openjdk.java.net/browse/JDK-8244579 refers to a manual test, but it's probably very hard to automate this. |
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.
Looks good to me
Tested with your fix and ran Test case provided in JBS (WebViewUserObjectLeakage) didn't exceeds more than 50 user objects (Which is same as in 14-GA build).
@arun-joseph This change now passes all automated pre-integration checks. When the change also fulfills all project specific requirements, type
Since the source branch of this PR was last updated there have been 2 commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid automatic rebasing, please merge ➡️ To integrate this PR with the above commit message to the |
/integrate |
@arun-joseph The following commits have been pushed to master since your change was applied:
Your commit was automatically rebased without conflicts. Pushed as commit a13a642. |
Cause: The Window Class
RunLoopMessageWindow
is never registered (this happens because registerRunLoopMessageWindowClass() is moved to MainThreadWin.cpp while openjfx uses MainThreadJava.cpp) and this causes every SetTimer() call in RunLoopWin.cpp to create a new user object instead of reusing the same object over again.Fix: Call registerRunLoopMessageWindowClass() from MainThreadJava.cpp
Test: To verify open any webpage using WebView on WIndows, with and without the fix and compare the number of user objects created using Windows Task Manager.
Progress
Issue
Reviewers
Download
$ git fetch https://git.openjdk.java.net/jfx pull/229/head:pull/229
$ git checkout pull/229