From 306114207d6ff6c3ec6d63f5ab6b4ff9e1dd7d4e Mon Sep 17 00:00:00 2001 From: Alan Conway Date: Tue, 27 Jan 2009 02:08:25 +0000 Subject: Cluster rename: dump -> update, newbie -> joiner git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@737971 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/qpid/cluster/ClusterPlugin.cpp | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'cpp/src/qpid/cluster/ClusterPlugin.cpp') diff --git a/cpp/src/qpid/cluster/ClusterPlugin.cpp b/cpp/src/qpid/cluster/ClusterPlugin.cpp index 79c34d6873..2a3df8f465 100644 --- a/cpp/src/qpid/cluster/ClusterPlugin.cpp +++ b/cpp/src/qpid/cluster/ClusterPlugin.cpp @@ -21,7 +21,7 @@ #include "qpid/cluster/Cluster.h" #include "qpid/cluster/ConnectionCodec.h" -#include "qpid/cluster/DumpClient.h" +#include "qpid/cluster/UpdateClient.h" #include "qpid/broker/Broker.h" #include "qpid/Plugin.h" @@ -87,43 +87,43 @@ struct ClusterOptions : public Options { } }; -struct DumpClientIdAllocator : management::IdAllocator +struct UpdateClientIdAllocator : management::IdAllocator { qpid::sys::AtomicValue sequence; - DumpClientIdAllocator() : sequence(0x4000000000000000LL) {} + UpdateClientIdAllocator() : sequence(0x4000000000000000LL) {} uint64_t getIdFor(management::Manageable* m) { - if (isDumpQueue(m) || isDumpExchange(m) || isDumpSession(m) || isDumpBinding(m)) { + if (isUpdateQueue(m) || isUpdateExchange(m) || isUpdateSession(m) || isUpdateBinding(m)) { return ++sequence; } else { return 0; } } - bool isDumpQueue(management::Manageable* manageable) + bool isUpdateQueue(management::Manageable* manageable) { qpid::broker::Queue* queue = dynamic_cast(manageable); - return queue && queue->getName() == DumpClient::DUMP; + return queue && queue->getName() == UpdateClient::UPDATE; } - bool isDumpExchange(management::Manageable* manageable) + bool isUpdateExchange(management::Manageable* manageable) { qpid::broker::Exchange* exchange = dynamic_cast(manageable); - return exchange && exchange->getName() == DumpClient::DUMP; + return exchange && exchange->getName() == UpdateClient::UPDATE; } - bool isDumpSession(management::Manageable* manageable) + bool isUpdateSession(management::Manageable* manageable) { broker::SessionState* session = dynamic_cast(manageable); - return session && session->getId().getName() == DumpClient::DUMP; + return session && session->getId().getName() == UpdateClient::UPDATE; } - bool isDumpBinding(management::Manageable* manageable) + bool isUpdateBinding(management::Manageable* manageable) { broker::Exchange::Binding* binding = dynamic_cast(manageable); - return binding && binding->queue->getName() == DumpClient::DUMP; + return binding && binding->queue->getName() == UpdateClient::UPDATE; } }; @@ -155,7 +155,7 @@ struct ClusterPlugin : public Plugin { broker->getExchanges().registerExchange(cluster->getFailoverExchange()); ManagementBroker* mgmt = dynamic_cast(ManagementAgent::Singleton::getInstance()); if (mgmt) { - std::auto_ptr allocator(new DumpClientIdAllocator()); + std::auto_ptr allocator(new UpdateClientIdAllocator()); mgmt->setAllocator(allocator); } } -- cgit v1.2.1