Uploaded image for project: 'ActiveMQ Artemis'
  1. ActiveMQ Artemis
  2. ARTEMIS-874

ThreadGroup memory leak

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.5.0
    • 2.1.0
    • None
    • None

    Description

      Each ActiveMQConnection has a failoverListenerExecutor, which is initialized using the code

      Executors.newFixedThreadPool(1, ActiveMQThreadFactory.defaultThreadFactory());
      

      Which creates a new ActiveMQThreadFactory and the factory has a ThreadGroup. When ThreadGroups are created, they are added to an array on their parent ThreadGroup. In our testing, the array of ThreadGroups just keeps growing as we keep creating ActiveMQConnections. The problem seems to be that nobody is destroying the ThreadGroups (ThreadGroup.destroy()). Note: the ActiveMQConnection etc are all cleaned up correctly.

      I've managed to workaround this issue by caching the ActiveMQConnection but in some environments this might not be possible.

      Attachments

        Activity

          People

            Unassigned Unassigned
            damien.hollis Damien Hollis
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: