diff options
| author | Alan Conway <aconway@apache.org> | 2010-06-22 13:29:52 +0000 |
|---|---|---|
| committer | Alan Conway <aconway@apache.org> | 2010-06-22 13:29:52 +0000 |
| commit | a49decc7d56bdb704a5d1580058c0da57e9a9353 (patch) | |
| tree | af0acf1f9e7e5f48336407ae438e11528db75b38 /cpp/src/qpid/sys/ClusterSafe.cpp | |
| parent | 265841a55cca55a7d3f8eea1d9e9c24a5fc2e350 (diff) | |
| download | qpid-python-a49decc7d56bdb704a5d1580058c0da57e9a9353.tar.gz | |
Fix cluster broker crashes when management is active.
Cluser brokers were exiting with errors "modified cluster state
outside cluster context" and "confirmed < (50+0) but only sent < (49+0)"
Fix was to:
- delay completion of incoming update till update connection closes.
- delay addding new connections to managment until connection is announced.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@956882 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/sys/ClusterSafe.cpp')
| -rw-r--r-- | cpp/src/qpid/sys/ClusterSafe.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/cpp/src/qpid/sys/ClusterSafe.cpp b/cpp/src/qpid/sys/ClusterSafe.cpp index e051591afd..6105fc96c7 100644 --- a/cpp/src/qpid/sys/ClusterSafe.cpp +++ b/cpp/src/qpid/sys/ClusterSafe.cpp @@ -43,8 +43,15 @@ void assertClusterSafe() { } } -ClusterSafeScope::ClusterSafeScope() { inContext = true; } -ClusterSafeScope::~ClusterSafeScope() { inContext = false; } +ClusterSafeScope::ClusterSafeScope() { + assert(!inContext); + inContext = true; +} + +ClusterSafeScope::~ClusterSafeScope() { + assert(inContext); + inContext = false; +} void enableClusterSafe() { inCluster = true; } |
