private void runTestAtomicity(long millisToRun, int numWriters, int numGetters, int numScanners,
    int numUniqueRows, boolean useMob) throws Exception {
    List<String> args = Lists.newArrayList("-millis", String.valueOf(millisToRun), "-numWriters",
      String.valueOf(numWriters), "-numGetters", String.valueOf(numGetters), "-numScanners",
      String.valueOf(numScanners), "-numUniqueRows", String.valueOf(numUniqueRows), "-crazyFlush");
    if (useMob) {
      args.add("-useMob");
    }
    tool.run(args.toArray(new String[0]));
  }
Test case that uses multiple threads to read and write multifamily rows into a table, verifying
that reads never see partially-complete writes. This can run as a junit test, or with a main()
function which runs against a real cluster (eg for testing with failures, region movement, etc)
hbase-server/src/test/java/org/apache/hadoop/hbase/AcidGuaranteesTestBase.java