public boolean isScanMetricsEnabled() {
    byte[] attr = getAttribute(Scan.SCAN_ATTRIBUTES_METRICS_ENABLE);
    return attr == null ? false : Bytes.toBoolean(attr);
  }
Returns True if collection of scan metrics is enabled. For advanced users.
hbase-client/src/main/java/org/apache/hadoop/hbase/client/Scan.java