use of com.navercorp.pinpoint.common.server.bo.LocalAsyncIdBo in project pinpoint by naver.
the class SpanFactoryTest method testFastLocalAsyncIdBo_empty.
@Test
public void testFastLocalAsyncIdBo_empty() {
TSpanEvent tSpanEvent = new TSpanEvent();
LocalAsyncIdBo localAsyncIdBo = spanFactory.fastLocalAsyncIdBo(Collections.singletonList(tSpanEvent));
Assert.assertNull(localAsyncIdBo);
}
use of com.navercorp.pinpoint.common.server.bo.LocalAsyncIdBo in project pinpoint by naver.
the class SpanFactoryTest method testFullScanLocalAsyncIdBo_empty.
@Test
public void testFullScanLocalAsyncIdBo_empty() {
TSpanEvent tSpanEvent = new TSpanEvent();
TSpanChunk tSpanChunk = new TSpanChunk();
tSpanChunk.setSpanEventList(Arrays.asList(tSpanEvent, tSpanEvent));
LocalAsyncIdBo localAsyncIdBo = spanFactory.fullScanLocalAsyncIdBo(tSpanChunk);
Assert.assertNull(localAsyncIdBo);
}
use of com.navercorp.pinpoint.common.server.bo.LocalAsyncIdBo in project pinpoint by naver.
the class SpanEncoderV0 method encodeSpanChunkQualifier.
@Override
public ByteBuffer encodeSpanChunkQualifier(SpanEncodingContext<SpanChunkBo> encodingContext) {
final SpanChunkBo spanChunkBo = encodingContext.getValue();
final List<SpanEventBo> spanEventBoList = spanChunkBo.getSpanEventBoList();
final SpanEventBo firstEvent = getFirstSpanEvent(spanEventBoList);
LocalAsyncIdBo localAsyncId = spanChunkBo.getLocalAsyncId();
return encodeQualifier(TYPE_SPAN_CHUNK, spanChunkBo, firstEvent, localAsyncId);
}
use of com.navercorp.pinpoint.common.server.bo.LocalAsyncIdBo in project pinpoint by naver.
the class SpanFactory method fastLocalAsyncIdBo.
@VisibleForTesting
LocalAsyncIdBo fastLocalAsyncIdBo(List<TSpanEvent> tSpanEventList) {
final TSpanEvent first = tSpanEventList.get(0);
if (isSetAsyncId(first)) {
final int asyncId = first.getAsyncId();
final short asyncSequence = first.getAsyncSequence();
return new LocalAsyncIdBo(asyncId, asyncSequence);
}
return null;
}
use of com.navercorp.pinpoint.common.server.bo.LocalAsyncIdBo 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;
}
Aggregations