Search in sources :

Example 1 with PCmdActiveThreadLightDump

use of com.navercorp.pinpoint.grpc.trace.PCmdActiveThreadLightDump in project pinpoint by naver.

the class GrpcActiveThreadLightDumpService method handle.

@Override
public void handle(PCmdRequest request, ProfilerCommandServiceGrpc.ProfilerCommandServiceStub profilerCommandServiceStub) {
    logger.info("simpleCommandService:{}", request);
    PCmdActiveThreadLightDump commandActiveThreadLightDump = request.getCommandActiveThreadLightDump();
    PCmdActiveThreadLightDumpRes.Builder builder = PCmdActiveThreadLightDumpRes.newBuilder();
    PCmdResponse commonResponse = PCmdResponse.newBuilder().setResponseId(request.getRequestId()).build();
    builder.setCommonResponse(commonResponse);
    builder.setType(JAVA);
    builder.setSubType(JvmUtils.getType().name());
    builder.setVersion(JvmUtils.getVersion().name());
    List<PActiveThreadLightDump> activeThreadDumpList = getActiveThreadDumpList(commandActiveThreadLightDump);
    builder.addAllThreadDump(activeThreadDumpList);
    profilerCommandServiceStub.commandActiveThreadLightDump(builder.build(), EmptyStreamObserver.create());
}
Also used : PCmdActiveThreadLightDump(com.navercorp.pinpoint.grpc.trace.PCmdActiveThreadLightDump) PCmdActiveThreadLightDumpRes(com.navercorp.pinpoint.grpc.trace.PCmdActiveThreadLightDumpRes) PActiveThreadLightDump(com.navercorp.pinpoint.grpc.trace.PActiveThreadLightDump) PCmdResponse(com.navercorp.pinpoint.grpc.trace.PCmdResponse)

Aggregations

PActiveThreadLightDump (com.navercorp.pinpoint.grpc.trace.PActiveThreadLightDump)1 PCmdActiveThreadLightDump (com.navercorp.pinpoint.grpc.trace.PCmdActiveThreadLightDump)1 PCmdActiveThreadLightDumpRes (com.navercorp.pinpoint.grpc.trace.PCmdActiveThreadLightDumpRes)1 PCmdResponse (com.navercorp.pinpoint.grpc.trace.PCmdResponse)1