@Override
  protected Ratio getRatio() {
    Integer numValue = numerator.getValue();
    Integer denomValue = denominator.getValue();
    if(numValue != null && denomValue != null) {
      return Ratio.of(numValue.doubleValue(), denomValue.doubleValue());
    }
    return Ratio.of(0d,0d);
  }
Combines two numeric metric variables into one gauge type metric displaying their ratio
standalone-metastore/metastore-common/src/main/java/org/apache/hadoop/hive/common/metrics/metrics2/MetricVariableRatioGauge.java