use of com.navercorp.pinpoint.grpc.trace.PThreadLightDump in project pinpoint by naver.
the class GrpcActiveThreadLightDumpService method createActiveThreadDump.
private PActiveThreadLightDump createActiveThreadDump(ThreadDump threadDump) {
final ActiveTraceSnapshot activeTraceInfo = threadDump.getActiveTraceSnapshot();
final ThreadInfo threadInfo = threadDump.getThreadInfo();
PThreadLightDump pThreadLightDump = createPThreadLightDump(threadInfo);
PActiveThreadLightDump.Builder builder = PActiveThreadLightDump.newBuilder();
builder.setStartTime(activeTraceInfo.getStartTime());
builder.setLocalTraceId(activeTraceInfo.getLocalTransactionId());
builder.setThreadDump(pThreadLightDump);
if (activeTraceInfo.isSampled()) {
builder.setSampled(true);
builder.setTransactionId(activeTraceInfo.getTransactionId());
builder.setEntryPoint(activeTraceInfo.getEntryPoint());
}
return builder.build();
}
Aggregations