Bug 1026354 - python client does not throw correct exception when exceed size of qpid.paging page
python client does not throw correct exception when exceed size of qpid.pagin...
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: qpid-cpp (Show other bugs)
3.0
Unspecified Unspecified
low Severity low
: 3.0
: ---
Assigned To: Gordon Sim
Eric Sammons
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-11-04 08:47 EST by Zdenek Kraus
Modified: 2015-01-21 07:55 EST (History)
5 users (show)

See Also:
Fixed In Version: qpid-cpp-0.22-25.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-01-21 07:55:41 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Apache JIRA QPID-5290 None None None Never

  None (edit)
Description Zdenek Kraus 2013-11-04 08:47:14 EST
Description of problem:
When using the qpid.paging feature and python sends a message larger than size of page then only 'qpid.messaging.exceptions.ConnectionError: connection aborted' is thrown on session.sync(). But there should be exception on client for exceeding the page size.

Version-Release number of selected component (if applicable):
python-qpid-0.22-5

How reproducible:
100%

Steps to Reproduce:
1. ./drain  "test_qpid_paging_reject_oversized;{'node': {'x-declare': {'arguments': {'qpid.flow_stop_count': 0, 'qpid.page_factor': 1, 'qpid.flow_resume_count': 0, 'qpid.flow_stop_size': 0, 'qpid.paging': True, 'qpid.max_pages_loaded': 32, 'qpid.flow_resume_size': 0}}}, 'create': 'always'}"

2. ./spout "test_qpid_paging_reject_oversized" "<CONTENT LARGER THAN 4kB>"


Actual results:
Traceback (most recent call last):
  File "/var/dtests/node_data/clients/spout.py", line 115, in <module>
    snd.send(msg)
  File "<string>", line 6, in send
  File "/usr/lib/python2.6/site-packages/qpid/messaging/endpoints.py", line 888, in send
    self.sync(timeout=timeout)
  File "<string>", line 6, in sync
  File "/usr/lib/python2.6/site-packages/qpid/messaging/endpoints.py", line 900, in sync
    if not self._ewait(lambda: self.acked >= mno, timeout=timeout):
  File "/usr/lib/python2.6/site-packages/qpid/messaging/endpoints.py", line 813, in _ewait
    result = self.session._ewait(lambda: self.error or predicate(), timeout)
  File "/usr/lib/python2.6/site-packages/qpid/messaging/endpoints.py", line 580, in _ewait
    result = self.connection._ewait(lambda: self.error or predicate(), timeout)
  File "/usr/lib/python2.6/site-packages/qpid/messaging/endpoints.py", line 219, in _ewait
    self.check_error()
  File "/usr/lib/python2.6/site-packages/qpid/messaging/endpoints.py", line 212, in check_error
    raise e
qpid.messaging.exceptions.ConnectionError: connection aborted


Expected results:
## excpetion from C++, so something simmilar:
2013-11-04 14:18:59 [Client] warning Broker closed connection: 501, Message is larger than page size for queue backed by /var/lib/qpidd/test_qpid_paging_reject_oversized (/builddir/build/BUILD/qpid-0.22/cpp/src/qpid/broker/PagedQueue.cpp:106)
  framing-error: Message is larger than page size for queue backed by /var/lib/qpidd/test_qpid_paging_reject_oversized (/builddir/build/BUILD/qpid-0.22/cpp/src/qpid/broker/PagedQueue.cpp:106) at /usr/lib64/perl5/vendor_perl/qpid/messaging/Session.pm line 204.


Additional info:
Comment 1 Gordon Sim 2013-11-04 11:15:06 EST
This is a broker bug, as the broker closes the connection with this error rather than raising a session exception (over 0-10) or closing the link (1.0).
Comment 2 Gordon Sim 2013-11-04 12:08:18 EST
Fixed upstream: https://svn.apache.org/r1538684

Note You need to log in before you can comment on or make changes to this bug.