Qpid
  1. Qpid
  2. QPID-3835

[Java broker] DurableSubscriptions without a selector on 0-10 connections will initially be unsubscribed at reconnect following upgrade of a legacy message store

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: 0.14
    • Fix Version/s: 0.15
    • Component/s: Java Broker
    • Labels:
      None

      Description

      DurableSubscriptions without a selector on 0-10 connections will initially be unsubscribed at reconnect following upgrade of a legacy message store. If an older broker release is upgraded to the current format, the bindings for a DurableSubscriptions backing queue must be modified if it previously had no selector, to ensure the client can correctly reconnect to the DurableSubscription without having the existing messages lost due to an unsubscribe() bring performed.

      This is because the newer clients send the server-side selector argument with an empty value to signfify the lack of a selector (to allow later querying if the selector has changed in any way when using the 0-10 client) whereas old clients used the complete lack of the argument to signal this. As a result, when determining if the selector has changed following a store upgrade from a legacy broker, the client would incorrectly believe it had and follow the JMS spec behaviour of doing an unsubscribe() before continuing, which would have the effect of deleting the backing queue. The bindings of such queues should be manipulated during the upgrade process to add the selector argument if it isnt already present.

        Activity

        Hide
        Keith Wall added a comment -

        Minor comment only against the test code.

        In BDBStoreUpgradeTestPreparer there is an exception listener installed which prints the exception to stderr. It would be better if the code were changed to check explicitly that there was no exception (or at the very least logging to stdout where it less likely to go unnoticed).

        Show
        Keith Wall added a comment - Minor comment only against the test code. In BDBStoreUpgradeTestPreparer there is an exception listener installed which prints the exception to stderr. It would be better if the code were changed to check explicitly that there was no exception (or at the very least logging to stdout where it less likely to go unnoticed).
        Hide
        Robbie Gemmell added a comment -

        BDBStoreUpgradeTestPreparer isn't actually a test and is something you run manually so you should see the output, all that checking would do is generate more output you would still have to look at to know.

        Show
        Robbie Gemmell added a comment - BDBStoreUpgradeTestPreparer isn't actually a test and is something you run manually so you should see the output, all that checking would do is generate more output you would still have to look at to know.
        Hide
        Robbie Gemmell added a comment -

        Given previous comments I am just resolving this

        Show
        Robbie Gemmell added a comment - Given previous comments I am just resolving this

          People

          • Assignee:
            Keith Wall
            Reporter:
            Robbie Gemmell
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development