Project

General

Profile

Actions

bug #7904

closed

DerivedUnitFacadeFieldUnitCacheStrategy.getCollectorAndFieldNumber() creates temporary Team objects which can not be garbage collected.

Added by Andreas Kohlbecker over 5 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Highest
Category:
cdmlib
Target version:
Start date:
Due date:
% Done:

100%

Estimated time:
Severity:
normal
Found in Version:

Description

The root cause for the excessive memory allocation reported in #7900 is the DerivedUnitFacadeFieldUnitCacheStrategy.getCollectorAndFieldNumber() method in which new Teams are created temporarily in order to create title cache strings. When adding the collector person to this Team the team is registered as PropertyChangeListener to the Person which creates a strong reference between both. The temporary Team objects now can no longer be cleaned up by the garbage collector:


Files

Team-merged-paths.png (102 KB) Team-merged-paths.png Andreas Kohlbecker, 11/13/2018 02:06 PM

Related issues

Related to EDIT - task #9678: Remove Derived- and FieldUnitFacadeCacheStrategiesClosedAndreas Müller

Actions
Copied from EDIT - bug #7900: Excessive heap consuption in RegistrationWorkingsetEditor with big workingsetsClosedAndreas Kohlbecker

Actions
Actions #1

Updated by Andreas Kohlbecker over 5 years ago

  • Copied from bug #7900: Excessive heap consuption in RegistrationWorkingsetEditor with big workingsets added
Actions #2

Updated by Andreas Kohlbecker over 5 years ago

The creation of Teams in this methods seems to be completely unnecessary

Actions #3

Updated by Andreas Kohlbecker over 5 years ago

  • Status changed from New to Feedback
  • Assignee changed from Andreas Kohlbecker to Andreas Müller
  • % Done changed from 0 to 10

I suggest two modifications:

  1. DerivedUnitFacadeFieldUnitCacheStrategy.getCollectorAndFieldNumber() without the unnecessary Team.NewInstance()
  2. removal of the registration of the person as PropertyChangeListerer to the Team
Actions #4

Updated by Andreas Müller over 5 years ago

  • Subject changed from DerivedUnitFacadeFieldUnitCacheStrategy.getCollectorAndFieldNumber() creates temporary Team objects which can not be grabage collected. to DerivedUnitFacadeFieldUnitCacheStrategy.getCollectorAndFieldNumber() creates temporary Team objects which can not be garbage collected.
Actions #5

Updated by Andreas Müller about 5 years ago

  • Status changed from Feedback to In Progress
  • Assignee changed from Andreas Müller to Andreas Kohlbecker

what is the situation here. Is this already implemented and needs review or does it need a decision which step to go?

Actions #6

Updated by Andreas Kohlbecker about 5 years ago

  • Status changed from In Progress to Feedback
  • Assignee changed from Andreas Kohlbecker to Andreas Müller

we need to decide between the alternative solutions suggested in comment 3

If we can decide on this quickly we could apply the according changes for this release otherwise we need to move the issue to the next release and set it to HIGHEST

Actions #7

Updated by Andreas Müller about 5 years ago

  • Target version changed from Release 5.5 to Release 5.6

As we decided to only work on review tickets and easy to fix critical bugs for this version I suggest to move to next version. Or is this critical?

Actions #8

Updated by Andreas Kohlbecker about 5 years ago

  • Priority changed from New to Highest

Andreas Müller wrote:

As we decided to only work on review tickets and easy to fix critical bugs for this version I suggest to move to next version. Or is this critical?

I fully agree in moving this issue to 5.6 .Since this is a major bug we should set the priority to HIGHEST in order to avoid that this issue is being missed.

Actions #9

Updated by Andreas Müller about 5 years ago

  • Target version changed from Release 5.6 to Release 5.7

As release is urgent now I have to move again to next milestone

Actions #10

Updated by Andreas Müller almost 5 years ago

  • Target version changed from Release 5.7 to Release 5.8
Actions #11

Updated by Andreas Müller almost 3 years ago

  • Status changed from Feedback to Resolved
  • Assignee changed from Andreas Müller to Andreas Kohlbecker
  • Target version changed from Release 5.8 to Release 5.25
  • % Done changed from 10 to 50

I guess this is solved with #9678. So the implemented solution is modification 1. The new cache strategy does not use an explicit new Team instance anymore.

Please review.

Actions #12

Updated by Andreas Müller almost 3 years ago

  • Related to task #9678: Remove Derived- and FieldUnitFacadeCacheStrategies added
Actions #13

Updated by Andreas Kohlbecker almost 3 years ago

  • Target version changed from Release 5.25 to Release 5.45
Actions #14

Updated by Andreas Kohlbecker over 2 years ago

  • Status changed from Resolved to Closed
  • Assignee changed from Andreas Kohlbecker to Andreas Müller
  • Target version changed from Release 5.45 to Release 5.27
  • % Done changed from 50 to 100

code looks good. I also tested with yourkit, ticket can be closed.

Actions #15

Updated by Andreas Kohlbecker over 2 years ago

  • Target version changed from Release 5.27 to Release 5.25

ahh this was solved for Release 5.25

Actions

Also available in: Atom PDF