Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-7081432

AppContext holds strong reference to the context class loader even if it is not needed

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P4
    • tbd
    • 8
    • client-libs
    • None
    • generic
    • generic

    Description

      The AppContext class holds the strong reference to the context class loader even if it is not needed anymore.
      Steps to reproduce:
      1. Create custom class loader
      2. Set it is as a context loader of the current thread
      3. Create a class object from this class loader
      4. Call any method that creates an AppContext instance
         For example, java.awt.Window.getWindows()
      5. Replace a context loader with another one
      6. Ensure that class could not be collected by GC.
      See attachement.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              malenkov Sergey Malenkov (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Imported:
                Indexed: