diff options
author | Alan Conway <aconway@apache.org> | 2010-01-27 22:20:51 +0000 |
---|---|---|
committer | Alan Conway <aconway@apache.org> | 2010-01-27 22:20:51 +0000 |
commit | 57b7cdbd9e431291eb336b8de7998b91eb414d78 (patch) | |
tree | 025c02d4943c6fdb5b00bc461ea64bfdc876a520 /qpid/cpp/src/qpid/management/ManagementAgent.h | |
parent | 1ec7e8f8e2f56c52e70eed200ef8adc827c75b11 (diff) | |
download | qpid-python-57b7cdbd9e431291eb336b8de7998b91eb414d78.tar.gz |
Added PeriodicTimer interface for periodic tasks that need cluster synchronization.
The ManagementAgent's periodic prociessing uses PeriodicTimer.
PeriodicTimerImpl is the default implementation for stand-alone
brokers, simple wrapper for sys::Timer.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@903866 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/src/qpid/management/ManagementAgent.h')
-rw-r--r-- | qpid/cpp/src/qpid/management/ManagementAgent.h | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/qpid/cpp/src/qpid/management/ManagementAgent.h b/qpid/cpp/src/qpid/management/ManagementAgent.h index 1c06e5896b..3dea8ce3c7 100644 --- a/qpid/cpp/src/qpid/management/ManagementAgent.h +++ b/qpid/cpp/src/qpid/management/ManagementAgent.h @@ -26,7 +26,7 @@ #include "qpid/broker/Exchange.h" #include "qpid/framing/Uuid.h" #include "qpid/sys/Mutex.h" -#include "qpid/sys/Timer.h" +#include "qpid/sys/PeriodicTimer.h" #include "qpid/broker/ConnectionToken.h" #include "qpid/management/ManagementObject.h" #include "qpid/management/ManagementEvent.h" @@ -105,15 +105,6 @@ public: void importSchemas(framing::Buffer& inBuf); private: - struct Periodic : public qpid::sys::TimerTask - { - ManagementAgent& agent; - - Periodic (ManagementAgent& agent, uint32_t seconds); - virtual ~Periodic (); - void fire (); - }; - // Storage for tracking remote management agents, attached via the client // management agent API. // @@ -205,7 +196,7 @@ private: std::string dataDir; uint16_t interval; qpid::broker::Broker* broker; - qpid::sys::Timer* timer; + qpid::sys::PeriodicTimer* timer; uint16_t bootSequence; uint32_t nextObjectId; uint32_t brokerBank; |