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

OutOfMemorr Exception while generating the cobertura report

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Critical
    • Resolution: Incomplete
    • Component/s: cobertura-plugin
    • Labels:
      None
    • Environment:
      Platform: All, OS: Windows 2000
    • Similar Issues:

      Description

      We are seeing the following error :

      Publishing Cobertura coverage report...
      Publishing Cobertura coverage results...
      FATAL: Java heap space
      java.lang.OutOfMemoryError: Java heap space
      at hudson.plugins.cobertura.targets.CoveragePaint.copyOf(CoveragePaint.java:77)
      at hudson.plugins.cobertura.targets.CoveragePaint.ensureSize
      (CoveragePaint.java:50)
      at hudson.plugins.cobertura.targets.CoveragePaint.paint(CoveragePaint.java:83)
      at hudson.plugins.cobertura.targets.CoverageResult.paint
      (CoverageResult.java:136)
      at hudson.plugins.cobertura.CoberturaXmlHandler.startElement
      (CoberturaCoverageParser.java:214)
      at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement
      (AbstractSAXParser.java:533)
      at
      com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElemen
      t(AbstractXMLDocumentParser.java:220)
      at com.sun.org.apache.xerces.internal.impl.dtd.XMLDTDValidator.emptyElement
      (XMLDTDValidator.java:819)
      at
      com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStart
      Element(XMLDocumentFragmentScannerImpl.java:872)
      at
      com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentC
      ontentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1693)
      at
      com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocum
      ent(XMLDocumentFragmentScannerImpl.java:368)
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse
      (XML11Configuration.java:834)
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse
      (XML11Configuration.java:764)
      at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse
      (XMLParser.java:148)
      at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse
      (AbstractSAXParser.java:1242)
      at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
      at javax.xml.parsers.SAXParser.parse(SAXParser.java:176)
      at hudson.plugins.cobertura.CoberturaCoverageParser.parse
      (CoberturaCoverageParser.java:77)
      at hudson.plugins.cobertura.CoberturaCoverageParser.parse
      (CoberturaCoverageParser.java:48)
      at hudson.plugins.cobertura.CoberturaPublisher.perform
      (CoberturaPublisher.java:259)
      at hudson.model.AbstractBuild$AbstractRunner.performAllBuildStep
      (AbstractBuild.java:372)
      at hudson.model.AbstractBuild$AbstractRunner.performAllBuildStep
      (AbstractBuild.java:360)
      at hudson.model.Build$RunnerImpl.post2(Build.java:183)
      at hudson.model.AbstractBuild$AbstractRunner.post(AbstractBuild.java:345)
      at hudson.model.Run.run(Run.java:947)
      at hudson.model.Build.run(Build.java:112)
      at hudson.model.ResourceController.execute(ResourceController.java:93)
      at hudson.model.Executor.run(Executor.java:119)

        Attachments

          Issue Links

            Activity

            Hide
            mdonohue mdonohue added a comment -

            dup

                • This issue has been marked as a duplicate of 3597 ***
            Show
            mdonohue mdonohue added a comment - dup This issue has been marked as a duplicate of 3597 ***
            Hide
            davidmc24 davidmc24 added a comment -

            This was marked as a duplicate of a patch, but the patch is no longer being pursued. Thus, this is back to being a viable issue.

            Show
            davidmc24 davidmc24 added a comment - This was marked as a duplicate of a patch, but the patch is no longer being pursued. Thus, this is back to being a viable issue.
            Hide
            bond Ravi Teja Lokineni added a comment - - edited

            As seen in the attached screenshot, if you configure those settings(Global properties). It'll act as a workaround for this problem.

            Show
            bond Ravi Teja Lokineni added a comment - - edited As seen in the attached screenshot, if you configure those settings(Global properties). It'll act as a workaround for this problem.
            Hide
            jprosevear JP Rosevear added a comment -

            There are several memory reduction commits on CoveragePaint.java since the last update on this ticket. Closing this as incomplete since if there is still a problem it would need a new assessment.

            commit daf038cf41e67beca0edbbdc7c3a6940abe1fd72
            Author: Kohsuke Kawaguchi <kk@kohsuke.org>
            Date: Thu Oct 11 14:11:50 2012 -0700

            More memory saving.

            Lines with branches are relatively rare. Introduce a dedicated subtype for non-zero branch coverage information so that if there's no branching information, we can save 8 more b

            commit acf4b9dc4e0170943a84326ec66cd242771d4de8
            Author: Kohsuke Kawaguchi <kk@kohsuke.org>
            Date: Thu Oct 11 14:01:32 2012 -0700

            use fly-weight pattern to save more memory

            commit 32b902a583ce2943f7b01791f12d010adfefce8d
            Author: Kohsuke Kawaguchi <kk@kohsuke.org>
            Date: Thu Oct 11 13:52:03 2012 -0700

            CoveragePaintDetails is made immutable in preparation for the flyweight pattern

            commit f957b3333c25748bf134d90c78f7626ac05012a2
            Author: Jesse Glick <jglick@cloudbees.com>
            Date: Thu Sep 27 13:42:37 2012 -0400

            gnu.trove.map.hash.TIntObjectHashMap yields ~5.5% savings on coverage-with-lots-of-data.xml.

            Show
            jprosevear JP Rosevear added a comment - There are several memory reduction commits on CoveragePaint.java since the last update on this ticket. Closing this as incomplete since if there is still a problem it would need a new assessment. commit daf038cf41e67beca0edbbdc7c3a6940abe1fd72 Author: Kohsuke Kawaguchi <kk@kohsuke.org> Date: Thu Oct 11 14:11:50 2012 -0700 More memory saving. Lines with branches are relatively rare. Introduce a dedicated subtype for non-zero branch coverage information so that if there's no branching information, we can save 8 more b commit acf4b9dc4e0170943a84326ec66cd242771d4de8 Author: Kohsuke Kawaguchi <kk@kohsuke.org> Date: Thu Oct 11 14:01:32 2012 -0700 use fly-weight pattern to save more memory commit 32b902a583ce2943f7b01791f12d010adfefce8d Author: Kohsuke Kawaguchi <kk@kohsuke.org> Date: Thu Oct 11 13:52:03 2012 -0700 CoveragePaintDetails is made immutable in preparation for the flyweight pattern commit f957b3333c25748bf134d90c78f7626ac05012a2 Author: Jesse Glick <jglick@cloudbees.com> Date: Thu Sep 27 13:42:37 2012 -0400 gnu.trove.map.hash.TIntObjectHashMap yields ~5.5% savings on coverage-with-lots-of-data.xml.

              People

              • Assignee:
                Unassigned
                Reporter:
                gkothari gkothari
              • Votes:
                6 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: