qpid-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kai Hudalla <sophokles...@gmail.com>
Subject [proton-j] handling of link-credit
Date Wed, 01 Mar 2017 14:31:19 GMT
Hi,

we are working on the Eclipse Hono project where we use vertx-proton and
(implicitly) proton-j under the hood for exchanging large amounts of messages
using AMQP 1.0.

During our tests I stumbled across the way that proton-j seems to handle link-
credit being exchanged via FLOWs.
My understanding is the following:

Assuming that we have a link established between a Receiver (r) and a Sender (s)
with a current link-credit of 4 and a delivery count of 20 on both sides.

When invoking r.flow(6), the given credit (6) is _added_ to the receiver's
current credit resulting in r.getCredit() returning 10.

When the FLOW is then flushed to the sender, the sender seems to _add_ the link-
credit from the FLOW to its already existing credit. Analogously, this results in
s.getCredit() now returning 10.

With this approach, it doesn't seem to be possible to stop the sender from
sending messages. The only thing a receiver can do is to wait until the sender
has used up all its credit (which may be a lot given that with the current
approach the sender's credit can pile up substantially).

Or am I mistaken?

Also, I cannot find the code where the link credit is actually updated from a
FLOW received from a Receiver. Can you point me to the right class?

Regards,
Kai

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org


Mime
View raw message