public static void setup() throws Exception {
    miniHS2 = new MiniHS2(new HiveConf());

    confOverlay.put(HiveConf.ConfVars.HIVE_SUPPORT_CONCURRENCY.varname, "false");
    confOverlay.put(HiveConf.ConfVars.SEMANTIC_ANALYZER_HOOK.varname,
            TestHs2Metrics.MetricCheckingHook.class.getName());
    confOverlay.put(HiveConf.ConfVars.HIVE_SERVER2_METRICS_ENABLED.varname, "true");

    miniHS2.start(confOverlay);
  }
Abstract class for connection metrics tests. Implementors of this class are
{@link TestHs2ConnectionMetricsBinary} and {@link TestHs2ConnectionMetricsBinary}. These two
classes are responsible for testing the connection metrics either in binary or in http mode.
itests/hive-unit/src/test/java/org/apache/hive/jdbc/miniHS2/Hs2ConnectionMetrics.java