diff options
author | Alan Conway <aconway@apache.org> | 2009-05-19 21:18:52 +0000 |
---|---|---|
committer | Alan Conway <aconway@apache.org> | 2009-05-19 21:18:52 +0000 |
commit | 285ca60cf814ce4b96813e929ced910d53097aef (patch) | |
tree | 347254ab8c4b2c27d6a095ccdac7ed444ed993b0 /cpp/src/qpid/cluster/OutputInterceptor.cpp | |
parent | fe0a36ba0edb47757a7bc7331764631ebd20205e (diff) | |
download | qpid-python-285ca60cf814ce4b96813e929ced910d53097aef.tar.gz |
Instrumentation for measuring latencies.
Compiled out of normal builds, enable with -DQPID_LATENCY_TRACKER.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@776463 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/cluster/OutputInterceptor.cpp')
-rw-r--r-- | cpp/src/qpid/cluster/OutputInterceptor.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/cpp/src/qpid/cluster/OutputInterceptor.cpp b/cpp/src/qpid/cluster/OutputInterceptor.cpp index 9062edc846..a7ec82128b 100644 --- a/cpp/src/qpid/cluster/OutputInterceptor.cpp +++ b/cpp/src/qpid/cluster/OutputInterceptor.cpp @@ -24,6 +24,7 @@ #include "qpid/framing/ClusterConnectionDeliverDoOutputBody.h" #include "qpid/framing/AMQFrame.h" #include "qpid/log/Statement.h" +#include "qpid/sys/LatencyTracker.h" #include <boost/current_function.hpp> @@ -41,7 +42,10 @@ OutputInterceptor::OutputInterceptor(Connection& p, sys::ConnectionOutputHandler moreOutput(), doingOutput() {} +LATENCY_TRACK(extern sys::LatencyTracker<const AMQBody*> doOutputTracker;) + void OutputInterceptor::send(framing::AMQFrame& f) { + LATENCY_TRACK(doOutputTracker.finish(f.getBody())); parent.getCluster().checkQuorum(); { // FIXME aconway 2009-04-28: locking around next-> may be redundant |