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/Connection.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/Connection.cpp')
| -rw-r--r-- | cpp/src/qpid/cluster/Connection.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cpp/src/qpid/cluster/Connection.cpp b/cpp/src/qpid/cluster/Connection.cpp index 394749aad2..17fcf6deb5 100644 --- a/cpp/src/qpid/cluster/Connection.cpp +++ b/cpp/src/qpid/cluster/Connection.cpp @@ -404,11 +404,13 @@ void Connection::shadowSetUser(const std::string& userId) { connection->setUserId(userId); } -void Connection::consumerState(const string& name, bool blocked, bool notifyEnabled, const SequenceNumber& position) +void Connection::consumerState(const string& name, bool blocked, bool notifyEnabled, const SequenceNumber& position, + uint32_t usedMsgCredit, uint32_t usedByteCredit) { broker::SemanticState::ConsumerImpl::shared_ptr c = semanticState().find(name); c->position = position; c->setBlocked(blocked); + if (c->getCredit().isWindowMode()) c->getCredit().consume(usedMsgCredit, usedByteCredit); if (notifyEnabled) c->enableNotify(); else c->disableNotify(); updateIn.consumerNumbering.add(c); } |
