Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-19544

OutOfMemory due to unbounded storage in OldDataMonitor

    XMLWordPrintable

Details

    Description

      The data map in hudson.diagnosis.OldDataMonitor keeps growing on my machine.

      I have removed an old plugin, which has stored it's settings in all project files.

      Now, on each load/access of a project a new FreeStyleProject object seems to be created and each time the old data is found and the project (as it is a Saveable) is stored as containing old data in the data map of the OldDataMonitor instance.
      One would think that this should not be a problem with only 20 projects but FreeStyleProject does not implement equals and hashCode and therefore every single project object is kept around in this map.
      After a week since the last restart it has accumulated a total of over 200k map entries totaling a whopping 1GB of heap memory.

      I would love to remove this old data but because of bug JENKINS-18809 I can't even do that. I will remove it by hand.

      Attachments

        1. 1.png
          1.png
          217 kB
        2. 2.png
          2.png
          78 kB

        Issue Links

          Activity

            rbaradari Ramin Baradari created issue -
            rbaradari Ramin Baradari made changes -
            Field Original Value New Value
            Link This issue is related to JENKINS-18809 [ JENKINS-18809 ]
            rbaradari Ramin Baradari made changes -
            Labels memory-leak
            jglick Jesse Glick made changes -
            Labels memory-leak memory-leak performance
            nieschinhio Michael Niestegge made changes -
            Attachment 1.png [ 25504 ]
            Attachment 2.png [ 25505 ]
            jglick Jesse Glick made changes -
            Link This issue depends on JENKINS-20950 [ JENKINS-20950 ]
            jglick Jesse Glick made changes -
            Description The {{data} map in {{hudson.diagnosis.OldDataMonitor}} keeps growing on my machine.

            I have removed an old plugin, which has stored it's settings in all project files.

            Now, on each load/access of a project a new {{FreeStyleProject}} object seems to be created and each time the old data is found and the project (as it is a Saveable) is stored as containing old data in the {{data}} map of the {{OldDataMonitor}} instance.
            One would think that this should not be a problem with only 20 projects but {{FreeStyleProject}} does not implement equals and hashCode and therefore every single project object is kept around in this map.
            After a week since the last restart it has accumulated a total of over 200k map entries totaling a whopping 1GB of heap memory.

            I would love to remove this old data but because of bug JENKINS-18809 I can't even do that. I will remove it by hand.
            The {{data}} map in {{hudson.diagnosis.OldDataMonitor}} keeps growing on my machine.

            I have removed an old plugin, which has stored it's settings in all project files.

            Now, on each load/access of a project a new {{FreeStyleProject}} object seems to be created and each time the old data is found and the project (as it is a Saveable) is stored as containing old data in the {{data}} map of the {{OldDataMonitor}} instance.
            One would think that this should not be a problem with only 20 projects but {{FreeStyleProject}} does not implement equals and hashCode and therefore every single project object is kept around in this map.
            After a week since the last restart it has accumulated a total of over 200k map entries totaling a whopping 1GB of heap memory.

            I would love to remove this old data but because of bug JENKINS-18809 I can't even do that. I will remove it by hand.
            jglick Jesse Glick made changes -
            Assignee Jesse Glick [ jglick ]
            jglick Jesse Glick made changes -
            Status Open [ 1 ] In Progress [ 3 ]
            scm_issue_link SCM/JIRA link daemon made changes -
            Resolution Fixed [ 1 ]
            Status In Progress [ 3 ] Resolved [ 5 ]
            jglick Jesse Glick made changes -
            Labels memory-leak performance lts-candidate memory-leak performance
            olivergondza Oliver Gondža made changes -
            Labels lts-candidate memory-leak performance 1.554.1-fixed memory-leak performance
            danielbeck Daniel Beck made changes -
            Link This issue is related to JENKINS-22261 [ JENKINS-22261 ]
            jglick Jesse Glick made changes -
            Link This issue depends on JENKINS-24358 [ JENKINS-24358 ]
            rtyler R. Tyler Croy made changes -
            Workflow JNJira [ 150998 ] JNJira + In-Review [ 193767 ]

            People

              jglick Jesse Glick
              rbaradari Ramin Baradari
              Votes:
              7 Vote for this issue
              Watchers:
              14 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: