qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Petr Svoboda <petr.svob...@centrumholdings.com>
Subject InsufficientCapacity with small sender capacity while sending persistent messages to qpid-cpp 0.10
Date Mon, 19 Sep 2011 10:24:59 GMT
Hi!

I have troubles with sending persistent messages to persistent queue.
When I set small sender capacity, after it is once filled, sender will
never recover.

If I set sender capacity to 10, sender is able to send only 10 messages
before filling capacity (sometimes little bit more).

When I use timeout, InsufficientCapacity exception is raised and than it
is not possible to send messages anymore.

When I don't use timeout, sender just waits forever once capacity is filled.

With growing capacity, it is usually possible to send more messages
(thousands) before sender gets stuck. With capacity set to 100 or more,
I'm not able to reproduce it.

I use this code (python):

...
snd = ssn.sender(address, durable=True)
snd.capacity = 10
while True:
   msg = Message(subject="test",
           properties={"spout-id": "%7d" % count},
           content="X"*30)
   try:
           snd.send(msg, sync=False, timeout=0.5)
   except exceptions.InsufficientCapacity:
           time.sleep(1)

If I use sync sending, it works. If the queue or messages are not
durable, it works too.

All sent messages are received from queue and acked - the sender
capacity is occupied by messages already delivered to someone else.

I'm using qpid-cpp broker 0.10 and python bindings 0.10. It's built form
RHEL 6.0 sources. It behaved the same, when I used python bindings
generated by swig.

I'm not able to test it with 0.12, because it is crashing with
persistent message store on my system.

Is it bug or I just misuse the api?

Thanks for any help!

--Petr S.

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:users-subscribe@qpid.apache.org


Mime
View raw message