Bug 1332143

Summary: Broker fails to restart after sending too big message into paged queue
Product: Red Hat Enterprise MRG Reporter: Barbora Vassova <bvassova>
Component: qpid-cppAssignee: Gordon Sim <gsim>
Status: CLOSED ERRATA QA Contact: Zdenek Kraus <zkraus>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 3.2CC: gsim, jross, mcressma, zkraus
Target Milestone: 3.2.5   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: qpid-cpp-1.36.0-2 Doc Type: Bug Fix
Doc Text:
Cause: If you have a durable paged queue and send a durable message that is too large to fit in a single page, the broker rejects it, which is expected based on current implementation. However, it still goes ahead and writes the message to disk. Consequence: Then if you stop and subsequently attempt to restart the broker, it fails to start (with the same error message). Fix: The broker now does not write the durable message to disk if it is too large to fit in a single page, Result: and the broker no longer fails to start up after such a message is detected.
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-07-04 07:49:26 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Barbora Vassova 2016-05-02 11:15:21 UTC
Description of problem:
When using durable paged queues, sending durable message with content bigger than the page factor fails with "Message is larger than page size for queue" error message (this is expected). However, when you stop and subsequently attempt to start the broker, it fails (with the same error message). It seems that the durable message in store is blocking the start up, although it shouldn't have been stored in the first place. 

Version-Release number of selected component (if applicable):
qpid-cpp-server-0.34-6.el6.x86_64

How reproducible:
Always

Steps to Reproduce:
1. qpid-config -a localhost:5672 add queue testqueue --argument=qpid.paging=true --argument=qpid.page_factor=1 --argument=qpid.max_pages_loaded=1 --durable
2. qpid-send -b localhost:5672 -a testqueue --content-size 5000 --durable yes 
3. service qpidd stop
4. service qpidd start 

Actual results:
broker fails to start

Expected results:
broker starts

Additional info:

Comment 1 Gordon Sim 2016-05-02 18:43:57 UTC
Fixed upstream: https://svn.apache.org/r1742020

Comment 3 Zdenek Kraus 2017-04-25 12:49:51 UTC
Tested on RHEL 6 i386, x86_64 and RHEL7 x86_64, with following packages:
qpid-cpp-client-1.36.0-5
qpid-cpp-client-devel-1.36.0-5
qpid-cpp-client-devel-docs-0.34-21
qpid-cpp-client-rdma-1.36.0-5
qpid-cpp-debuginfo-1.36.0-5
qpid-cpp-server-1.36.0-5
qpid-cpp-server-ha-1.36.0-5
qpid-cpp-server-linearstore-1.36.0-5
qpid-cpp-server-rdma-1.36.0-5

Fix works as expected.

->VERIFIED

Comment 5 errata-xmlrpc 2017-07-04 07:49:26 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2017:1671