aboutsummaryrefslogtreecommitdiff
path: root/zencore/stats.cpp
diff options
context:
space:
mode:
authorDan Engelbrecht <[email protected]>2022-09-22 23:59:56 +0200
committerGitHub <[email protected]>2022-09-22 23:59:56 +0200
commit050b61eee042dd23cfb8ad1744f876ec00932198 (patch)
treecad4dbc80b385efde67bd1df88108d9049c991e2 /zencore/stats.cpp
parentAdd elapsed seconds per individual request from upstream (#167) (diff)
downloadzen-050b61eee042dd23cfb8ad1744f876ec00932198.tar.xz
zen-050b61eee042dd23cfb8ad1744f876ec00932198.zip
De/more upstream details (#168)v0.1.6-pre9v0.1.6-pre10
* Pass along endpoint info for each upstream request * Add more timing details in log * more log details for single item upstream fetch * DISABLEDQUERY over SKIP
Diffstat (limited to 'zencore/stats.cpp')
-rw-r--r--zencore/stats.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/zencore/stats.cpp b/zencore/stats.cpp
index f783ccd3d..372bc42f8 100644
--- a/zencore/stats.cpp
+++ b/zencore/stats.cpp
@@ -416,9 +416,16 @@ OperationTiming::Scope::Scope(OperationTiming& Outer) : m_Outer(Outer), m_StartT
OperationTiming::Scope::~Scope()
{
+ Stop();
+}
+
+void
+OperationTiming::Scope::Stop()
+{
if (m_StartTick != 0)
{
m_Outer.Update(GetHifreqTimerValue() - m_StartTick);
+ m_StartTick = 0;
}
}