Skip to content

8295796: ScrollPaneSkin: memory leak when changing skin #928

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

andy-goryachev-oracle
Copy link
Contributor

@andy-goryachev-oracle andy-goryachev-oracle commented Oct 21, 2022

as determined by SkinMemoryLeakTest (remove line 174) and a leak tester
https://github.com/andy-goryachev-oracle/Test/blob/main/src/goryachev/apps/LeakTest.java

caused by:

  • adding and not removing listeners
  • adding and not removing event handlers/filters

NOTE:
this fix requires JDK-8295242 scroll bar fixes, as well as JDK-8294809 ListenerHelper


Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Issues

  • JDK-8295796: ScrollPaneSkin: memory leak when changing skin
  • JDK-8295242: ScrollBarSkin: memory leak when changing skin

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jfx pull/928/head:pull/928
$ git checkout pull/928

Update a local copy of the PR:
$ git checkout pull/928
$ git pull https://git.openjdk.org/jfx pull/928/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 928

View PR using the GUI difftool:
$ git pr show -t 928

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jfx/pull/928.diff

@bridgekeeper
Copy link

bridgekeeper bot commented Oct 21, 2022

👋 Welcome back angorya! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk
Copy link

openjdk bot commented Oct 21, 2022

⚠️ @andy-goryachev-oracle This pull request contains merges that bring in commits not present in the target repository. Since this is not a "merge style" pull request, these changes will be squashed when this pull request in integrated. If this is your intention, then please ignore this message. If you want to preserve the commit structure, you must change the title of this pull request to Merge <project>:<branch> where <project> is the name of another project in the OpenJDK organization (for example Merge jdk:master).

@andy-goryachev-oracle andy-goryachev-oracle marked this pull request as ready for review November 28, 2022 17:36
@openjdk openjdk bot added the rfr Ready for review label Nov 28, 2022
@mlbridge
Copy link

mlbridge bot commented Nov 28, 2022

Webrevs

@andy-goryachev-oracle
Copy link
Contributor Author

contains changes from #914 so perhaps that should be reviewed/integrated first.

@kevinrushforth
Copy link
Member

In that case, you might consider closing PR #914 , and then adding that issue to this PR with /issue add 8295242, so they can be reviewed together?

@andy-goryachev-oracle
Copy link
Contributor Author

/issue add 8295242

@andy-goryachev-oracle
Copy link
Contributor Author

/issue add JDK-8295242

@openjdk
Copy link

openjdk bot commented Nov 28, 2022

@andy-goryachev-oracle
Adding additional issue to issue list: 8295242: ScrollBarSkin: memory leak when changing skin.

@openjdk
Copy link

openjdk bot commented Nov 28, 2022

@andy-goryachev-oracle
Updating description of additional solved issue: 8295242: ScrollBarSkin: memory leak when changing skin.

Copy link
Collaborator

@aghaisas aghaisas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The fix looks good.
I have a cleanup comment on the Test.

@@ -170,8 +170,8 @@ public static Collection<Object[]> data() {
MenuButton.class,
Pagination.class,
PasswordField.class,
ScrollBar.class,
ScrollPane.class,
//ScrollBar.class,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can remove these lines instead of commenting them out.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aghaisas :
will clean up this area once the last PR is integrated, otherwise we'll have constant merge conflicts here (every skin memory leak PR touches this)

@openjdk
Copy link

openjdk bot commented Nov 29, 2022

@andy-goryachev-oracle This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8295796: ScrollPaneSkin: memory leak when changing skin
8295242: ScrollBarSkin: memory leak when changing skin

Reviewed-by: aghaisas

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 2 new commits pushed to the master branch:

  • 4ad8582: 8265828: [TestBug] Save and restore the default Locale in javafx.base unit test LocalDateTimeStringConverterTest
  • d040c1f: 8297680: JavaDoc example for PseudoClass has minor typo

Please see this link for an up-to-date comparison between the source branch of this pull request and the master branch.
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

As you do not have Committer status in this project an existing Committer must agree to sponsor your change. Possible candidates are the reviewers of this PR (@aghaisas) but any other Committer may sponsor as well.

➡️ To flag this PR as ready for integration with the above commit message, type /integrate in a new comment. (Afterwards, your sponsor types /sponsor in a new comment to perform the integration).

@openjdk openjdk bot added the ready Ready to be integrated label Nov 29, 2022
@andy-goryachev-oracle
Copy link
Contributor Author

/integrate

@openjdk openjdk bot added the sponsor Ready to sponsor label Nov 29, 2022
@openjdk
Copy link

openjdk bot commented Nov 29, 2022

@andy-goryachev-oracle
Your change (at version 3e9678a) is now ready to be sponsored by a Committer.

@kevinrushforth
Copy link
Member

/sponsor

@openjdk
Copy link

openjdk bot commented Nov 29, 2022

Going to push as commit fbad15d.
Since your change was applied there have been 2 commits pushed to the master branch:

  • 4ad8582: 8265828: [TestBug] Save and restore the default Locale in javafx.base unit test LocalDateTimeStringConverterTest
  • d040c1f: 8297680: JavaDoc example for PseudoClass has minor typo

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot added the integrated Pull request has been integrated label Nov 29, 2022
@openjdk openjdk bot closed this Nov 29, 2022
@openjdk openjdk bot removed ready Ready to be integrated rfr Ready for review sponsor Ready to sponsor labels Nov 29, 2022
@openjdk
Copy link

openjdk bot commented Nov 29, 2022

@kevinrushforth @andy-goryachev-oracle Pushed as commit fbad15d.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@andy-goryachev-oracle andy-goryachev-oracle deleted the 8295796.scroll.pane.skin branch November 29, 2022 17:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integrated Pull request has been integrated
Development

Successfully merging this pull request may close these issues.

3 participants