Description of problem: Already subscribed consumer stops to receive messages when another subscription to the same queue with different subject is initiated. see 'Steps to Reproduce' for more details. Version-Release number of selected component (if applicable): qpid-cpp-*-0.22-11 How reproducible: 100% Steps to Reproduce: 1. create a shared queue 'q' # drain --connection-options "{ protocol: 'amqp1.0' }" "q;{create:always}" 2. subscribe a cosumer1 to queue 'q' using filter 'a' # drain -f --connection-options "{ protocol: 'amqp1.0' }" q/a 3. send several messages to towards queue 'q' with subject set to 'a' # for i in $(seq 5); do ./spout --connection-options "{ protocol: 'amqp1.0' }" q/a; done 4. all the messages consumed by consumer1 as expected 5. subscribe cosumer2 to queue 'q' using different filter 'b' # drain -f --connection-options "{ protocol: 'amqp1.0' }" q/b 6. repeat step 3 7. the consumer1 obtains only one message, then he stops to receive messages 8. the consumer2 may normally receive messages sent towards queue 'q' with subject set to 'b' # spout --connection-options "{ protocol: 'amqp1.0' }" q/b 9. after the consumer1 restart, the consumer1 gets the rest of the messages (that he didn't received in step 7) Actual results: subscribing a consumer to a queue using filter causes already subscribed consumer to stop receive messages Expected results: Already subscribed consumer continues to receive messages after another consumer is subscribed using different filter Additional info: terminal1 - publisher: # ./drain --connection-options "{ protocol: 'amqp1.0' }" "q;{create:always}" -- consumer1 has subscribed here -- # for i in $(seq 5); do ./spout --connection-options "{ protocol: 'amqp1.0' }" q/a; done -- consumer2 has subscribed here -- # for i in $(seq 5); do ./spout --connection-options "{ protocol: 'amqp1.0' }" q/a; done # for i in $(seq 5); do ./spout --connection-options "{ protocol: 'amqp1.0' }" q/b; done -- consumer1 restart -- terminal2 - consumer1: # ./drain -f --connection-options "{ protocol: 'amqp1.0' }" q/a Message(properties={spout-id:0e05ac1c-6bee-4966-b1af-89efda0e1883:0}, content='') Message(properties={spout-id:0e05ac1c-6bee-4966-b1af-89efda0e1883:0}, content='') Message(properties={spout-id:0e05ac1c-6bee-4966-b1af-89efda0e1883:0}, content='') Message(properties={spout-id:0e05ac1c-6bee-4966-b1af-89efda0e1883:0}, content='') Message(properties={spout-id:0e05ac1c-6bee-4966-b1af-89efda0e1883:0}, content='') -- consumer2 has subscribed here -- Message(properties={spout-id:0e05ac1c-6bee-4966-b1af-89efda0e1883:0}, content='') -- consumer1 stopped to receive messages -- ^C # ./drain -f --connection-options "{ protocol: 'amqp1.0' }" q/a Message(properties={spout-id:8ba06f2f-89f2-4604-b7b5-d8b211e435cb:0}, content='') Message(properties={spout-id:8ba06f2f-89f2-4604-b7b5-d8b211e435cb:0}, content='') Message(properties={spout-id:8ba06f2f-89f2-4604-b7b5-d8b211e435cb:0}, content='') Message(properties={spout-id:8ba06f2f-89f2-4604-b7b5-d8b211e435cb:0}, content='') terminal3 - consumer2: # ./drain -f --connection-options "{ protocol: 'amqp1.0' }" q/b Message(properties={spout-id:f1e5dfcf-281d-47b7-b91e-9d086cf37523:0}, content='') Message(properties={spout-id:f1e5dfcf-281d-47b7-b91e-9d086cf37523:0}, content='') Message(properties={spout-id:f1e5dfcf-281d-47b7-b91e-9d086cf37523:0}, content='') Message(properties={spout-id:f1e5dfcf-281d-47b7-b91e-9d086cf37523:0}, content='') Message(properties={spout-id:f1e5dfcf-281d-47b7-b91e-9d086cf37523:0}, content='')
Note that this also affects selectors (over both 0-10 and 1.0). It is a side-effect of the filtering logic added to queues (hence the skip-errata flag, since this will not have been released in product yet).
Fixed upstream: https://svn.apache.org/r1514907
This issue has been fixed. Verified on rhel6.4 (i386,x86_64). packages used for testing: qpid-cpp-*-0.22-13.el6