diff options
| author | Gordon Sim <gsim@apache.org> | 2007-08-02 18:09:48 +0000 |
|---|---|---|
| committer | Gordon Sim <gsim@apache.org> | 2007-08-02 18:09:48 +0000 |
| commit | 89aa36d093182e9e191c000504c174663932458f (patch) | |
| tree | 06d7e9a3feb4abdaab74b79c94e4352dfa40adaa /cpp/src/qpid/broker/SemanticHandler.cpp | |
| parent | 2290d4ed915f1202bcd6cd50b1a85f27f3eb6cd2 (diff) | |
| download | qpid-python-89aa36d093182e9e191c000504c174663932458f.tar.gz | |
Some restructuring of the client code:
* Introduced three separate 'handlers' for the connection, channel and execution 'layers'.
* Support for asynchronous retrieval of response or completion status.
* Channel methods no longer included in execution layers command id count.
git-svn-id: https://svn.apache.org/repos/asf/incubator/qpid/trunk/qpid@562212 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/broker/SemanticHandler.cpp')
| -rw-r--r-- | cpp/src/qpid/broker/SemanticHandler.cpp | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/cpp/src/qpid/broker/SemanticHandler.cpp b/cpp/src/qpid/broker/SemanticHandler.cpp index e9ec698400..27f484cfcb 100644 --- a/cpp/src/qpid/broker/SemanticHandler.cpp +++ b/cpp/src/qpid/broker/SemanticHandler.cpp @@ -68,7 +68,11 @@ void SemanticHandler::handleMethodInContext(boost::shared_ptr<qpid::framing::AMQ handleL4(method, context); //(if the frameset is complete) we can move the execution-mark //forward - ++(incoming.hwm); + + //temporary hack until channel management is moved to its own handler: + if (method->amqpClassId() != ChannelOpenBody::CLASS_ID) { + ++(incoming.hwm); + } //note: need to be more sophisticated than this if we execute //commands that arrive within an active message frameset (that @@ -175,8 +179,11 @@ RequestId SemanticHandler::send(shared_ptr<AMQBody> body, Correlator::Action act Mutex::ScopedLock l(outLock); uint8_t type(body->type()); if (type == REQUEST_BODY || type == RESPONSE_BODY || type == METHOD_BODY) { - ++outgoing.hwm; - //std::cout << "[" << this << "] allocated: " << outgoing.hwm.getValue() << " to " << *body << std::endl; + //temporary hack until channel management is moved to its own handler: + if (dynamic_pointer_cast<AMQMethodBody>(body)->amqpClassId() != ChannelOpenBody::CLASS_ID) { + ++outgoing.hwm; + //std::cout << "[" << this << "] allocated: " << outgoing.hwm.getValue() << " to " << *body << std::endl; + } } return ChannelAdapter::send(body, action); } |
