use of com.navercorp.pinpoint.grpc.trace.PJvmGcType in project pinpoint by naver.
the class GrpcStatMessageConverter method convertJvmGc.
private PJvmGc convertJvmGc(JvmGcMetricSnapshot jvmGcMetricSnapshot) {
final PJvmGc.Builder jvmGcBuilder = PJvmGc.newBuilder();
jvmGcBuilder.setJvmMemoryHeapMax(jvmGcMetricSnapshot.getJvmMemoryHeapMax());
jvmGcBuilder.setJvmMemoryHeapUsed(jvmGcMetricSnapshot.getJvmMemoryHeapUsed());
jvmGcBuilder.setJvmMemoryNonHeapMax(jvmGcMetricSnapshot.getJvmMemoryNonHeapMax());
jvmGcBuilder.setJvmMemoryNonHeapUsed(jvmGcMetricSnapshot.getJvmMemoryNonHeapUsed());
jvmGcBuilder.setJvmGcOldCount(jvmGcMetricSnapshot.getJvmGcOldCount());
jvmGcBuilder.setJvmGcOldTime(jvmGcMetricSnapshot.getJvmGcOldTime());
final PJvmGcType jvmGcType = this.jvmGcTypeConverter.toMessage(jvmGcMetricSnapshot.getType());
jvmGcBuilder.setType(jvmGcType);
if (jvmGcMetricSnapshot.getJvmGcDetailed() != null) {
final JvmGcDetailedMetricSnapshot jvmGcDetailedMetricSnapshot = jvmGcMetricSnapshot.getJvmGcDetailed();
final PJvmGcDetailed.Builder jvmGcDetailedBuilder = PJvmGcDetailed.newBuilder();
jvmGcDetailedBuilder.setJvmPoolNewGenUsed(jvmGcDetailedMetricSnapshot.getJvmPoolNewGenUsed());
jvmGcDetailedBuilder.setJvmPoolOldGenUsed(jvmGcDetailedMetricSnapshot.getJvmPoolOldGenUsed());
jvmGcDetailedBuilder.setJvmPoolSurvivorSpaceUsed(jvmGcDetailedMetricSnapshot.getJvmPoolSurvivorSpaceUsed());
jvmGcDetailedBuilder.setJvmPoolCodeCacheUsed(jvmGcDetailedMetricSnapshot.getJvmPoolCodeCacheUsed());
jvmGcDetailedBuilder.setJvmPoolPermGenUsed(jvmGcDetailedMetricSnapshot.getJvmPoolPermGenUsed());
jvmGcDetailedBuilder.setJvmPoolMetaspaceUsed(jvmGcDetailedMetricSnapshot.getJvmPoolMetaspaceUsed());
jvmGcDetailedBuilder.setJvmGcNewCount(jvmGcDetailedMetricSnapshot.getJvmGcNewCount());
jvmGcDetailedBuilder.setJvmGcNewTime(jvmGcDetailedMetricSnapshot.getJvmGcNewTime());
jvmGcBuilder.setJvmGcDetailed(jvmGcDetailedBuilder.build());
}
return jvmGcBuilder.build();
}
use of com.navercorp.pinpoint.grpc.trace.PJvmGcType in project pinpoint by naver.
the class GrpcAgentInfoMessageConverter method convertJvmInfo.
private PJvmInfo convertJvmInfo(final JvmInformation jvmInformation) {
final PJvmInfo.Builder builder = PJvmInfo.newBuilder();
builder.setVmVersion(jvmInformation.getJvmVersion());
PJvmGcType gcType = this.jvmGcTypeMessageConverter.toMessage(jvmInformation.getJvmGcType());
builder.setGcType(gcType);
return builder.build();
}
Aggregations