private void scanTable() {
    try {

      Result result;
      ResultScanner scanner = table.getScanner(fam);
      int counter = 0;
      while ((result = scanner.next()) != null) {
        byte[] key = result.getRow();
        assertTrue(Arrays.equals(result.getValue(fam, qualifier), Bytes.add(key, mobVal)));
        if (counter % 10000 == 0) {
          LOG.info("GET=" + counter + " key=" + Bytes.toInt(key));
        }
        counter++;
      }

      assertEquals(count, counter);
    } catch (Exception e) {
      e.printStackTrace();
      LOG.error("MOB Stress Test FAILED");
      if (HTU != null) {
        assertTrue(false);
      } else {
        System.exit(-1);
      }
    }
  }
Reproduction for MOB data loss 1. Settings: Region Size 200 MB, Flush threshold 800 KB. 2. Insert
10 Million records 3. MOB Compaction and Archiver a) Trigger MOB Compaction (every 2 minutes) b)
Trigger major compaction (every 2 minutes) c) Trigger archive cleaner (every 3 minutes) 4.
Validate MOB data after complete data load. This class is used by MobStressTool only. This is not
a unit test
hbase-server/src/test/java/org/apache/hadoop/hbase/mob/MobStressToolRunner.java