Uploaded image for project: 'AMQ Broker'
  1. AMQ Broker
  2. ENTMQBR-8141

AddressSize remains > 0 with messageCount = 0 when mixing protocols in producers and consumers

XMLWordPrintable

    • 3
    • False
    • None
    • False
    • Hide

      There is a zip file called "reproducer.zip"

      To run the reproducer:
      A) Unzip "reproducer.zip"
      B) Check "reproducer.sh" env variables and change
      C) Run "reproducer.sh"

      Following the steps that the script does:

      1) Create a broker, on port 61616
          The broker is created with an already provided "broker.xml"

      2) Start a 10000 messages producer 

      $ $BROKER_FOLDER/bin/artemis producer --protocol $PRODUCER_PROTOCOL --destination queue://myqueue --message-count 10000 --message-size 2048 --threads 10
       
      3) Start a 10000 messages consumer
       
      $ $BROKER_FOLDER/bin/artemis consumer --protocol $CONSUMER_PROTOCOL --destination queue://myqueue --message-count 100000
      4) Check the AddressSize JMX attribute on the queue

      $ curl -sH "Origin: http://localhost" "http://admin:admin@localhost:8161/console/jolokia/read/org.apache.activemq.artemis:broker=%220.0.0.0%22,component=addresses,address=%22myqueue%22/AddressSize"
      Getting AddressSize
      14964

      If do not have the "jq" command installed, the output will be shown as the full JSON response body from the curl command

      Show
      There is a zip file called "reproducer.zip" To run the reproducer: A) Unzip "reproducer.zip" B) Check "reproducer.sh" env variables and change C) Run "reproducer.sh" Following the steps that the script does: 1) Create a broker, on port 61616     The broker is created with an already provided "broker.xml" 2) Start a 10000 messages producer  $ $BROKER_FOLDER/bin/artemis producer --protocol $PRODUCER_PROTOCOL --destination queue://myqueue --message-count 10000 --message-size 2048 --threads 10   3) Start a 10000 messages consumer   $ $BROKER_FOLDER/bin/artemis consumer --protocol $CONSUMER_PROTOCOL --destination queue://myqueue --message-count 100000 4) Check the AddressSize JMX attribute on the queue $ curl -sH "Origin: http://localhost " "http://admin:admin@localhost:8161/console/jolokia/read/org.apache.activemq.artemis:broker=%220.0.0.0%22,component=addresses,address=%22myqueue%22/AddressSize" Getting AddressSize 14964 If do not have the "jq" command installed, the output will be shown as the full JSON response body from the curl command
    • Moderate

      Under certain conditions,  AddressSize JMX property is bigger than 0 after all messages on a destination were consumed. 
       
      I could reproduce this on my side, with the following test conditions:
       

      • global max size  = 100MB
      • queue max size = 200MB
      • Queue is ANYCAST
      • Producer uses AMQP protocol
      • Consumer uses CORE protocol
      • Produced and consumed  100.000 messages with 2k size, using Artemis cli tools
      • The consumer starts after the queue has all the messages, not before.

      I noticed the following on my tests:

      • When using the same protocol on both consumer and producer, the issue never happens
      • When I reboot the broker, the AddressSize number goes back to 0
      • It happens on both 7.10.3 and 7.11.0, but with 7.11.0 the remaining AddressSize number is much lower

      There is a script reproducer attached, with further instructions

              csuconic@redhat.com Clebert Suconic
              rhn-support-anarvaez Alfredo Narvaez
              Tiago Bueno Tiago Bueno
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: