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

When using client-individual ackMode python based STOMP consumer hangs while receiving messages

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Minor Minor
    • A-MQ 7.0.0.GA
    • None
    • None
    • None
    • Hide

      1)Add stomp transport to broker configuration:

       <transportConnector name="stomp" uri="stomp://localhost:61613"/>
      

      2)Start the broker.
      3)Download and install python client stomp.py-4.0.13.tar.gz from https://pypi.python.org/pypi/stomp.py:

      easy_install ./stomp.py-4.0.13.tar.gz
      

      3)Run listener_ind.py attached.

      ./listener_ind.py
      

      4)Run publisher1.py attached.

      ./publisher1.py
      
      Show
      1)Add stomp transport to broker configuration: <transportConnector name= "stomp" uri= "stomp: //localhost:61613" /> 2)Start the broker. 3)Download and install python client stomp.py-4.0.13.tar.gz from https://pypi.python.org/pypi/stomp.py: easy_install ./stomp.py-4.0.13.tar.gz 3)Run listener_ind.py attached. ./listener_ind.py 4)Run publisher1.py attached. ./publisher1.py

      Using the stomp client stomp.py-4.0.13, when sending 100000 messages to the consumer with client-individual ackMode, the consumer hangs at 52000 messages.

      All messages are enqueud to the topic. And consumer sends ack messages:

      12:25:45,579 | TRACE | .0.1:48954@61613 | StompIO                          | 132 - org.apache.activemq.activemq-osgi - 5.9.0.redhat-611421 | Received:
      ACK
      id:ID:dhcp-4-224.brq.redhat.com-51141-1422530721561-3:1
      

      Screenshot from hawtio:

      When setting prefetch to lower number (100 and 1), the consumer doesn't hang, but stops after consuming 75756 and 48129 messages respectfully.

      The details are below:
      The consumer is written in a way, that it should stop after consuming the message 'SHUTDOWN'.
      The message 'SHUTDOWN' is sent by publisher after sending all 100000 messages.

      When printing message numbers, looks that some messages starting from 292 are missing.
      Screenshot from hawtio:

      An old discussion about stomp and ACK:
      http://activemq.2283324.n4.nabble.com/Stomp-acking-and-prefetchSize-td2379487.html
      where they also recommend to set prefetch size to 1.

        1. topic-info.png
          topic-info.png
          10 kB
        2. listener_ind.py
          3 kB
        3. publisher1.py
          2 kB
        4. topic-info1.png
          topic-info1.png
          8 kB

              rh-ee-ataylor Andy Taylor
              emedvede Elena Medvedeva (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: