use of com.navercorp.pinpoint.profiler.monitor.metric.gc.ParallelGcGarbageCollectorMetric in project pinpoint by naver.
the class GarbageCollectorMetricProvider method get.
@Override
public GarbageCollectorMetric get() {
Map<String, Metric> garbageCollectorMetrics = garbageCollectorMetricSet.getMetrics();
Set<String> metricNames = garbageCollectorMetrics.keySet();
GarbageCollectorMetric garbageCollectorMetric;
if (metricNames.contains(MetricMonitorValues.METRIC_GC_SERIAL_OLDGEN_COUNT)) {
garbageCollectorMetric = new SerialGcGarbageCollectorMetric(garbageCollectorMetrics);
} else if (metricNames.contains(MetricMonitorValues.METRIC_GC_PS_OLDGEN_COUNT)) {
garbageCollectorMetric = new ParallelGcGarbageCollectorMetric(garbageCollectorMetrics);
} else if (metricNames.contains(MetricMonitorValues.METRIC_GC_CMS_OLDGEN_COUNT)) {
garbageCollectorMetric = new CmsGcGarbageCollectorMetric(garbageCollectorMetrics);
} else if (metricNames.contains(MetricMonitorValues.METRIC_GC_G1_OLDGEN_COUNT)) {
garbageCollectorMetric = new G1GcGarbageCollectorMetric(garbageCollectorMetrics);
} else {
garbageCollectorMetric = new UnknownGarbageCollectorMetric();
}
logger.info("loaded : {}", garbageCollectorMetric);
return garbageCollectorMetric;
}
Aggregations