use of com.navercorp.pinpoint.common.server.bo.SpanChunkBo in project pinpoint by naver.
the class Node method buildSpanChunkBaseAligns.
private List<Align> buildSpanChunkBaseAligns(List<SpanChunkBo> spanChunkBoList) {
if (CollectionUtils.isEmpty(spanChunkBoList)) {
return Collections.emptyList();
}
List<Align> alignList = new ArrayList<>();
for (SpanChunkBo chunkBo : spanChunkBoList) {
if (chunkBo.isAsyncSpanChunk()) {
// asyncSpanEvent
continue;
}
List<SpanEventBo> spanEventList = chunkBo.getSpanEventBoList();
for (SpanEventBo spanEventBo : spanEventList) {
if (logger.isTraceEnabled()) {
logger.trace("Populate spanEvent{seq={}, depth={}, event={}}", spanEventBo.getSequence(), spanEventBo.getDepth(), spanEventBo);
}
final Align spanEventAlign = this.newSpanEventAlign(chunkBo, spanEventBo);
alignList.add(spanEventAlign);
}
}
return alignList;
}
use of com.navercorp.pinpoint.common.server.bo.SpanChunkBo in project pinpoint by naver.
the class CallStackMock method push.
public void push() {
final SpanEventBo spanEvent = new SpanEventBo();
final int startElapsed = (int) (currentTime - spanBo.getStartTime());
currentTime++;
spanEvent.setStartElapsed(startElapsed);
spanEvent.setSequence(sequence++);
checkExtend(index + 1);
stack[index++] = spanEvent;
if (this.latestStackIndex != this.index) {
this.latestStackIndex = this.index;
spanEvent.setDepth(this.latestStackIndex);
}
final SpanEventAlign spanEventAlign;
if (this.async) {
LocalAsyncIdBo localAsyncIdBo = new LocalAsyncIdBo(asyncId, 1);
SpanChunkBo spanChunkBo = new SpanChunkBo();
spanChunkBo.setLocalAsyncId(localAsyncIdBo);
spanEventAlign = new SpanChunkEventAlign(spanBo, spanChunkBo, spanEvent);
} else {
spanEventAlign = new SpanEventAlign(spanBo, spanEvent);
}
callTree.add(spanEvent.getDepth(), spanEventAlign);
}
Aggregations