Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue #5786 : Revisit Statistics classes #5825

Merged
merged 2 commits into from Jan 12, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -70,7 +70,7 @@ public void run()
long queueLatency = System.nanoTime() - begin;
queueStats.decrement();
threadStats.increment();
queueLatencyStats.set(queueLatency);
queueLatencyStats.record(queueLatency);
long start = System.nanoTime();
try
{
Expand All @@ -80,7 +80,7 @@ public void run()
{
long taskLatency = System.nanoTime() - start;
threadStats.decrement();
taskLatencyStats.set(taskLatency);
taskLatencyStats.record(taskLatency);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you missed another call to set() few lines above.

}
}

Expand Down Expand Up @@ -110,7 +110,7 @@ public void reset()
@ManagedAttribute("the number of tasks executed")
public long getTasks()
{
return taskLatencyStats.getTotal();
return taskLatencyStats.getCount();
}

/**
Expand Down