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

ProtonAbstractReceiver memory leak

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Blocker
    • Resolution: Fixed
    • 2.17.0
    • 2.18.0
    • AMQP
    • None

    Description

      Hi,

      Thanks for a wonderfull broker.

      We were testing the new version of artemis, 2.16 and 2.17 and we noticed the memory will go up during our performance tests and eventually the garbace collector can no longer free enough memory to keep running.

      We are running spring integration and are using sync and async message flows which make use of artemis. With our async message flow we encountered no problems, but with the sync message flows we noticed the issues stated above.

      We tracked the issues by using MAT to a lambda in the class https://github.com/apache/activemq-artemis/blob/master/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/proton/ProtonAbstractReceiver.java

      A largemessage cleanup action is registered through the method addClosable on line 92. This lambda is not remembered for life cycle managment and never de-registered. It seems we create a lot of there ProtonAbstractReceivers through our way of messaging. And they pile up in the session. Only when we close the session memory is freed. That we create a large nr of ProtonAbstractReceiver might also not be correct. I doubt this because we see no issues in our async flows. I'm not sure what these ProtonAbstractReceivers are used for and when they are created and when not. Maybe there is a place where I could look like some related code or some documentation.

      I would like to make a unit tests and see if there is a way this can be fixed but could someone give me a hint when this ProtonAbstracReceiver is created and if there is already a test case resembling what I want to do so I can use that for a quick start?

      Attachments

        Issue Links

          Activity

            People

              gtully Gary Tully
              baselzinga Bas
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 3h 10m
                  3h 10m