use of com.navercorp.pinpoint.common.server.bo.SpanEventBo in project pinpoint by naver.
the class SpanFactory method buildSpanEventBoList.
private List<SpanEventBo> buildSpanEventBoList(List<TSpanEvent> spanEventList) {
if (CollectionUtils.isEmpty(spanEventList)) {
return new ArrayList<>();
}
List<SpanEventBo> spanEventBoList = new ArrayList<>(spanEventList.size());
for (TSpanEvent tSpanEvent : spanEventList) {
final SpanEventBo spanEventBo = buildSpanEventBo(tSpanEvent);
if (!spanEventFilter.filter(spanEventBo)) {
continue;
}
spanEventBoList.add(spanEventBo);
}
spanEventBoList.sort(SpanEventComparator.INSTANCE);
return spanEventBoList;
}
use of com.navercorp.pinpoint.common.server.bo.SpanEventBo in project pinpoint by naver.
the class SpanFactory method buildSpanChunkBo.
public SpanChunkBo buildSpanChunkBo(TSpanChunk tSpanChunk) {
final SpanChunkBo spanChunkBo = newSpanChunkBo(tSpanChunk);
final LocalAsyncIdBo localAsyncIdBo = getLocalAsyncId(tSpanChunk);
if (localAsyncIdBo != null) {
spanChunkBo.setLocalAsyncId(localAsyncIdBo);
}
List<TSpanEvent> spanEventList = tSpanChunk.getSpanEventList();
List<SpanEventBo> spanEventBoList = buildSpanEventBoList(spanEventList);
spanChunkBo.addSpanEventBoList(spanEventBoList);
long acceptedTime = acceptedTimeService.getAcceptedTime();
spanChunkBo.setCollectorAcceptTime(acceptedTime);
return spanChunkBo;
}
use of com.navercorp.pinpoint.common.server.bo.SpanEventBo in project pinpoint by naver.
the class SpanFactory method buildSpanEventBo.
// for test
public SpanEventBo buildSpanEventBo(TSpanEvent tSpanEvent) {
Objects.requireNonNull(tSpanEvent, "tSpanEvent");
final SpanEventBo spanEvent = new SpanEventBo();
bind(spanEvent, tSpanEvent);
return spanEvent;
}
use of com.navercorp.pinpoint.common.server.bo.SpanEventBo in project pinpoint by naver.
the class SpanFactory method buildSpanBo.
public SpanBo buildSpanBo(TSpan tSpan) {
final SpanBo spanBo = newSpanBo(tSpan);
List<TSpanEvent> spanEventList = tSpan.getSpanEventList();
List<SpanEventBo> spanEventBoList = buildSpanEventBoList(spanEventList);
spanBo.addSpanEventBoList(spanEventBoList);
long acceptedTime = acceptedTimeService.getAcceptedTime();
spanBo.setCollectorAcceptTime(acceptedTime);
return spanBo;
}
use of com.navercorp.pinpoint.common.server.bo.SpanEventBo in project pinpoint by naver.
the class CollectorGrpcSpanFactory method buildSpanBo.
@Override
public SpanBo buildSpanBo(PSpan pSpan, Header header) {
final SpanBo spanBo = this.grpcBinder.bindSpanBo(pSpan, header);
final long acceptedTime = acceptedTimeService.getAcceptedTime();
spanBo.setCollectorAcceptTime(acceptedTime);
final List<PSpanEvent> pSpanEventList = pSpan.getSpanEventList();
List<SpanEventBo> spanEventBos = buildSpanEventBoList(pSpanEventList);
spanBo.addSpanEventBoList(spanEventBos);
return spanBo;
}
Aggregations