Uploaded image for project: 'ActiveMQ Classic'
  1. ActiveMQ Classic
  2. AMQ-8617

RedeliveryPolicy:Exponential Backoff + NonBlockingRedelivery = too long delays

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • None
    • 5.18.0, 5.17.3
    • None
    • None

    Description

      Scenario on client:

      1. Employing RedeliveryPolicy with exponential backoff (keeping maximum redeliveries at default 6)
      2. Enabled non-blocking redelivery
      3. Receiving e.g. 100 consecutive poison messages which are rolled back repeatedly (which eventually should DLQ after max redeliveries)

      This will result in massive redelivery delays due to a logic bug.

      The reason is that redeliveryDelay is a field variable kept on the ActiveMQMessageConsumer, instead of being a property on the message - or that the redelivery delay was calculated per message based on the redelivery count.

      When consecutive messages rollbacks multiple times, the redeliveryDelay field is continuously multiplied by the backoff multiplier, resulting in enormous delays.

      Pull Request for fix, including test: https://github.com/apache/activemq/pull/843

      Attachments

        Activity

          People

            jbonofre Jean-Baptiste Onofré
            stolsvik Endre Stølsvik
            Votes:
            0 Vote for this issue
            Watchers:
            2 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 - 20m
                20m