Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[JENKINS-21921] Lazy loaded report details are never released
- SloccountResult.lazyLoad() caches the data to a member variable. SloccountResult objects (all build.xml files) are loaded during Jenkins startup and never released so Java garbage collector has no chance to trash the lazy loaded details since the reference exists forever. This is kind of a memory leak. - Lazy loading reads the data everytime and doesn't use any cache, saving of memory is now prefered to performace. It is not expected the user will show the details very often, so it should be ok. - Explicit calls of convertLegacyData() replaced by readResolve() from Java serialization with the same effect. - Report object made transient, null is always passed in SloccountPublisher while storing.
- Loading branch information
1 parent
f336a18
commit 32b1fa8
Showing
1 changed file
with
22 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters