Description of problem: If "qpid.alert_count_down" is set together with "qpid.alert_size_up" (or "qpid.alert_size_down" is set with "qpid.alert_count_up") the "threshold crossed decreasing" is generated even in case of the count of messages (bytes) in the queue does not cross the lower threshold; look at the next example, please: 1. Run two receivers to catch threshold crossing events: ./drain --forever "qmf.default.topic/agent.ind.event.org_apache_qpid_broker.queueThresholdCrossedUpward.#" ./drain --forever qmf.default.topic/agent.ind.event.org_apache_qpid_broker.queueThresholdCrossedDownward.#" 2. In another terminal send messages to cross the upward threshold: ./spout --count 12 --content "xxxxxxxxxx" "threshold_queue; {create:always, node:{x-declare:{arguments:{'qpid.alert_count_down': 3,'qpid.alert_size_up':114}}}}" The "Threshold crossed increasing" event is generated (should be OK). 3. Receive part of the messages to do not cross the lower threshold: ./drain --count 7 ""threshold_queue; {create:always, node:{x-declare:{arguments:{'qpid.alert_count_down': 3,'qpid.alert_size_up':114}}}}"" The "Threshold crossed decreasing" event is generated in this case, although there are still 5 messages in the "threshold_queue" (the lower threshold is set to 3 messages). I am not sure if this testing scenario is relevant; which of combinations of settings are supported. Could you possibly look at the combinations of threshold values and write which of them are supported? qpid.alert_count_down with qpid.alert_count_up - probably yes qpid.alert_size_down with qpid.alert_size_up - probably yes qpid.alert_count_down with qpid.alert_size_up ? qpid.alert_size_down with qpid.alert_count_up ? qpid.alert_size_down and qpid.alert_count_down with qpid.alert_size_up ? qpid.alert_size_down and qpid.alert_count_down with qpid.alert_count_up ? qpid.alert_size_down with qpid.alert_size_up and qpid.alert_count_up ? qpid.alert_count_down with qpid.alert_size_up and qpid.alert_count_up ? qpid.alert_size_down and qpid.alert_count_down with qpid.alert_size_up and qpid.alert_count_up ? Version-Release number of selected component (if applicable): qpid-cpp-0.22-18 How reproducible: 100% Steps to Reproduce: Try to follow steps above, please. Actual results: The "Threshold crossed decreasing" event is generated, although more messages (5) than set lower threshold (3) remain in the "threshold_queue" Expected results: The "Threshold crossed decreasing" event should not be generated in this case.
Created attachment 809397 [details] Example sketch The attached picture displays situation in the example above.
The behavior is affected by lower threshold, what is set automatically to one half of its respective upward threshold (size lower threshold in this case). Ted, thank you for your explanation. --> CLOSED - NOT A BUG