use of com.navercorp.pinpoint.web.vo.chart.TitledDataPoint in project pinpoint by naver.
the class LegacyAgentStatChartGroup method addActiveTraceData.
private void addActiveTraceData(AgentStat agentStat) {
long timestamp = agentStat.getTimestamp();
HistogramSchema schema = agentStat.getHistogramSchema();
if (schema != null) {
Map<SlotType, Integer> activeTraceCounts = agentStat.getActiveTraceCounts();
int fastCount = activeTraceCounts.get(SlotType.FAST);
if (fastCount != UNCOLLECTED_DATA) {
TitledDataPoint<Long, Integer> fastDataPoint = new TitledDataPoint<>(schema.getFastSlot().getSlotName(), timestamp, fastCount);
this.activeTraceFastChartBuilder.addDataPoint(fastDataPoint);
}
int normalCount = activeTraceCounts.get(SlotType.NORMAL);
if (normalCount != UNCOLLECTED_DATA) {
TitledDataPoint<Long, Integer> normalDataPoint = new TitledDataPoint<>(schema.getNormalSlot().getSlotName(), timestamp, normalCount);
this.activeTraceNormalChartBuilder.addDataPoint(normalDataPoint);
}
int slowCount = activeTraceCounts.get(SlotType.SLOW);
if (slowCount != UNCOLLECTED_DATA) {
TitledDataPoint<Long, Integer> slowDataPoint = new TitledDataPoint<>(schema.getSlowSlot().getSlotName(), timestamp, slowCount);
this.activeTraceSlowChartBuilder.addDataPoint(slowDataPoint);
}
int verySlowCount = activeTraceCounts.get(SlotType.VERY_SLOW);
if (verySlowCount != UNCOLLECTED_DATA) {
TitledDataPoint<Long, Integer> verySlowDataPoint = new TitledDataPoint<>(schema.getVerySlowSlot().getSlotName(), timestamp, verySlowCount);
this.activeTraceVerySlowChartBuilder.addDataPoint(verySlowDataPoint);
}
}
}
Aggregations