[ 
https://issues.apache.org/jira/browse/HBASE-20306?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16591742#comment-16591742
 ] 

Mike Drob commented on HBASE-20306:
-----------------------------------

{code}
+  protected boolean isProgressReporterRunning = false;
{code}
This might need to be volatile (or AtomicBoolean) since it is read from 
multiple threads? What happens if an exception is thrown from the {{run()}} 
body - then the {{waitForFinish()}} will never finish, right? Overall, we end 
up checking the {{numThreadsWorking.get() != 0)}} condition in two places now, 
when it's guaranteed to be true by the time isProgressReporterRunning changes 
values.

{code}
+      LOG.info("RUN SUMMARY: "
+          + "Keys="
+          + priorNumKeys
+          + ", cols="
+          + StringUtils.humanReadableInt(numCols.get())
+          + ", time="
+          + formatTime(time)
+          + ((priorNumKeys > 0 && time > 0) ? (" Overall: [" + "keys/s= "
+          + priorNumKeys * 1000 / time + ", latency="
+          + String.format("%.2f", (double)priorCumulativeOpTime / 
(double)priorNumKeys)
+          + " ms]") : "")
+      );
{code}
Can we pull the parts of this that are common to the in-progress reporting out 
into a helper method?

> LoadTestTool does not print summary at end of run
> -------------------------------------------------
>
>                 Key: HBASE-20306
>                 URL: https://issues.apache.org/jira/browse/HBASE-20306
>             Project: HBase
>          Issue Type: Bug
>          Components: tooling
>            Reporter: Mike Drob
>            Assignee: Colin Garcia
>            Priority: Major
>              Labels: beginner
>         Attachments: HBASE-20306.000.patch
>
>
> ltt currently prints status as it goes, but doesn't give a nice summary of 
> what happened so users have to infer it from the last status line printed.
> Would be nice to print a real summary with statistics about what was run.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to