Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-38769

File.deleteOnExit() Java API call causes JVM crashes on long running servers

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Low
    • None
    • 5.4.4, 5.8.2, 5.8.4, 5.8.5, 5.8.6, 5.8.8
    • None

    Description

      Summary

      The File.deleteOnExit API is flawed and causes JVM crashes on long running servers. See http://bugs.java.com/view_bug.do?bug_id=4513817 :

      Every time I use "ImageIO.write(img, "png", outStream)" a temporary file is
      created, and the "deleteOnExit()" function is called on that temporary file.
      Every "deleteOnExit()" allocates a "struct dlEntry" in the shared "io_util.c"
      native source file. This "struct dlEntry" is about 1K in size, and will never be
      freed until the system exits, so every time I do an ImageIO.write() I take up
      another 1K of memory!

      Notes

      • This will only affect long running servers

      Workaround

      • Restart server Confluence is running on occasionally

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              sbrannen@atlassian.com Branno
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: