public int getSampleCount() {
      if (active) {
        return archive.getTimeStamps().getSize() - firstTSidx;
      } else {
        return (lastTSidx + 1) - firstTSidx;
      }
    }
Returns the number of times this resource instance has been sampled.
geode-core/src/main/java/org/apache/geode/internal/statistics/StatArchiveReader.java