diff options
author | Gordon Sim <gsim@apache.org> | 2011-11-23 16:01:25 +0000 |
---|---|---|
committer | Gordon Sim <gsim@apache.org> | 2011-11-23 16:01:25 +0000 |
commit | c8f2e652489ca0fab6b4ce15416b16afdcd6b556 (patch) | |
tree | a434a0aaf73630fafebd5038e112d7e4efd7f5bc /cpp/src/qpid/cluster/UpdateClient.cpp | |
parent | ceca56258e7d3b8aabd2eadbd00857eb69e825f5 (diff) | |
download | qpid-python-c8f2e652489ca0fab6b4ce15416b16afdcd6b556.tar.gz |
QPID-3629: Changed management of credit window
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1205467 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/cluster/UpdateClient.cpp')
-rw-r--r-- | cpp/src/qpid/cluster/UpdateClient.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/cpp/src/qpid/cluster/UpdateClient.cpp b/cpp/src/qpid/cluster/UpdateClient.cpp index 2446c12f2b..25a3a3327c 100644 --- a/cpp/src/qpid/cluster/UpdateClient.cpp +++ b/cpp/src/qpid/cluster/UpdateClient.cpp @@ -535,14 +535,16 @@ void UpdateClient::updateConsumer( arg::resumeTtl = ci->getResumeTtl(), arg::arguments = ci->getArguments() ); - shadowSession.messageSetFlowMode(ci->getTag(), ci->isWindowing() ? FLOW_MODE_WINDOW : FLOW_MODE_CREDIT); - shadowSession.messageFlow(ci->getTag(), CREDIT_UNIT_MESSAGE, ci->getMsgCredit()); - shadowSession.messageFlow(ci->getTag(), CREDIT_UNIT_BYTE, ci->getByteCredit()); + shadowSession.messageSetFlowMode(ci->getTag(), ci->getCredit().isWindowMode() ? FLOW_MODE_WINDOW : FLOW_MODE_CREDIT); + shadowSession.messageFlow(ci->getTag(), CREDIT_UNIT_MESSAGE, ci->getCredit().allocated().messages); + shadowSession.messageFlow(ci->getTag(), CREDIT_UNIT_BYTE, ci->getCredit().allocated().bytes); ClusterConnectionProxy(shadowSession).consumerState( ci->getTag(), ci->isBlocked(), ci->isNotifyEnabled(), - ci->position + ci->position, + ci->getCredit().used().messages, + ci->getCredit().used().bytes ); consumerNumbering.add(ci.get()); |