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

Messages not marked as redelivered when durable connection closed improperly

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 5.15.6
    • 5.15.7, 5.16.0
    • Broker
    • None

    Description

      I noticed that if a connection is killed improperly (using kill -9 or network failure, etc) any prefetched messages for a durable subscription are not marked as redelivered because the logic on the broker does not check for the LAST_DELIVERED_UNKNOWN status (-2).

      However, when a queue subscription is closed improperly this flag does get checked. I think for the durable subscription case we should do the same thing (match the queue logic) and be checking and marking these messages that were already dispatched but have an unknown status with the JMS redelivery flag as they might potentially be duplicates to the client when the client reconnects. The spec just says the flag means messages may have been redelivered but there is no guarantee so I think it's fine to mark the flag in this use case.

      As a side note this is how Artemis behaves already.

      Attachments

        Activity

          People

            cshannon Christopher L. Shannon
            cshannon Christopher L. Shannon
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: