@Override
  public void alert(JvmGcMonitorMetrics.GcData gcData) {
    logger.warn(
        "Error metrics taken time: "
            + sdf.format(new Date(Long.parseLong(String.valueOf(gcData.getTimestamp())))));
    logger.warn("Gc Time Percentage: " + gcData.getGcTimePercentage() + "%");
    logger.warn(
        "Accumulated GC time within current observation window: "
            + gcData.getGcTimeWithinObsWindow()
            + " ms");
    logger.warn(
        "The observation window is from: "
            + sdf.format(new Date(Long.parseLong(String.valueOf(gcData.getStartObsWindowTs()))))
            + " to: "
            + sdf.format(new Date(Long.parseLong(String.valueOf(gcData.getTimestamp())))));
    logger.warn("The observation window time is: " + gcData.getCurrentObsWindowTs() + " ms.");
  }
Alert handler func User can tailor their handle logic here

@param gcData
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/service/metric/GcTimeAlerter.java