static RunResult runOneClient(final Class<? extends TestBase> cmd, Configuration conf,
    Connection con, AsyncConnection asyncCon, TestOptions opts, final Status status)
    throws IOException, InterruptedException {
    status.setStatus(
      "Start " + cmd + " at offset " + opts.startRow + " for " + opts.perClientRunRows + " rows");
    long totalElapsedTime;

    final TestBase t;
    try {
      if (AsyncTest.class.isAssignableFrom(cmd)) {
        Class<? extends AsyncTest> newCmd = (Class<? extends AsyncTest>) cmd;
        Constructor<? extends AsyncTest> constructor =
          newCmd.getDeclaredConstructor(AsyncConnection.class, TestOptions.class, Status.class);
        t = constructor.newInstance(asyncCon, opts, status);
      } else {
        Class<? extends Test> newCmd = (Class<? extends Test>) cmd;
        Constructor<? extends Test> constructor =
          newCmd.getDeclaredConstructor(Connection.class, TestOptions.class, Status.class);
        t = constructor.newInstance(con, opts, status);
      }
    } catch (NoSuchMethodException e) {
      throw new IllegalArgumentException("Invalid command class: " + cmd.getName()
        + ".  It does not provide a constructor as described by "
        + "the javadoc comment.  Available constructors are: "
        + Arrays.toString(cmd.getConstructors()));
    } catch (Exception e) {
      throw new IllegalStateException("Failed to construct command class", e);
    }
    totalElapsedTime = t.test();

    status.setStatus("Finished " + cmd + " in " + totalElapsedTime + "ms at offset " + opts.startRow
      + " for " + opts.perClientRunRows + " rows" + " ("
      + calculateMbps((long) (opts.perClientRunRows * opts.sampleRate), totalElapsedTime,
        getAverageValueLength(opts), opts.families, opts.columns)
      + ")");

    return new RunResult(totalElapsedTime, t.numOfReplyOverLatencyThreshold,
      t.numOfReplyFromReplica, t.getLatencyHistogram());
  }
Compute a throughput rate in MB/s.
@param rows   Number of records consumed.
@param timeMs Time taken in milliseconds.
@return String value with label, ie '123.76 MB/s'
hbase-diagnostics/src/main/java/org/apache/hadoop/hbase/PerformanceEvaluation.java