diff options
| author | Gordon Sim <gsim@apache.org> | 2009-03-04 13:22:03 +0000 |
|---|---|---|
| committer | Gordon Sim <gsim@apache.org> | 2009-03-04 13:22:03 +0000 |
| commit | 8df34ffd42c067ace66021c031bd46c398a36abe (patch) | |
| tree | d54f805f922b34deee3becec8cda16c6b7d81609 /cpp/src/qpid/SessionState.h | |
| parent | f029ec74824a402525c9441413976e204f2739a3 (diff) | |
| download | qpid-python-8df34ffd42c067ace66021c031bd46c398a36abe.tar.gz | |
QPID-1711: Ensure the session state between the two peers in an inter-broker bridging session are kept in sync.
(Also made changes to cancellation to ensure that the commands are only issued on the io thread of the connection)
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@750002 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/SessionState.h')
| -rw-r--r-- | cpp/src/qpid/SessionState.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/cpp/src/qpid/SessionState.h b/cpp/src/qpid/SessionState.h index bf4ff6d326..e99875c489 100644 --- a/cpp/src/qpid/SessionState.h +++ b/cpp/src/qpid/SessionState.h @@ -181,6 +181,20 @@ class SessionState { const SequenceSet& receivedIncomplete ); + /** + * So called 'push' bridges work by faking a subscribe request + * (and the accompanyingflows etc) to the local broker to initiate + * the outflow of messages for the bridge. + * + * As the peer doesn't send these it cannot include them in its + * session state. To keep the session state on either side of the + * bridge in sync, this hack allows the tracking of state for + * received messages to be disabled for the faked commands and + * subsequently re-enabled. + */ + void disableReceiverTracking(); + void enableReceiverTracking(); + private: struct SendState { @@ -209,6 +223,7 @@ class SessionState { uint32_t timeout; Configuration config; bool stateful; + bool receiverTrackingDisabled;//very nasty hack for 'push' bridges }; inline bool operator==(const SessionId& id, const SessionState& s) { return s == id; } |
