0
votes

I have upgraded to Spring Boot 2 which in turn has updated actuator. I was using the Spring Boot 1.* Actuator metrics field 'processors' like so:

{
"mem": 323621,
"mem.free": 70699,
"processors": 2,
....

But can't seem to find this in the Spring Boot 2 metrics names:

{
"names": [
"http.server.requests",
"jvm.buffer.memory.used",
"jvm.memory.committed",
"tomcat.global.request.max",
"jvm.memory.used",
"jdbc.connections.min",
"tomcat.sessions.created",
"tomcat.sessions.expired",
"logback.events",
"system.cpu.count",
"jvm.memory.max",
"jdbc.connections.active",
"jvm.gc.pause",
"process.files.max",
"jvm.threads.daemon",
"hikaricp.connections",
"process.start.time",
"hikaricp.connections.active",
"hikaricp.connections.creation.percentile",
"tomcat.global.error",
"tomcat.sessions.active.max",
"tomcat.global.sent",
"jvm.gc.live.data.size",
"process.files.open",
"hikaricp.connections.acquire",
"hikaricp.connections.timeout",
"hikaricp.connections.idle",
"hikaricp.connections.pending",
"jvm.buffer.total.capacity",
"hikaricp.connections.usage.percentile",
"tomcat.cache.access",
"jvm.threads.live",
"jvm.classes.loaded",
"jvm.classes.unloaded",
"hikaricp.connections.creation",
"jvm.gc.memory.promoted",
"tomcat.sessions.rejected",
"tomcat.sessions.alive.max",
"jvm.gc.memory.allocated",
"hikaricp.connections.usage",
"jvm.gc.max.data.size",
"jvm.buffer.count",
"process.cpu.usage",
"tomcat.servlet.request",
"process.uptime",
"system.load.average.1m",
"tomcat.global.received",
"tomcat.cache.hit",
"tomcat.threads.config.max",
"hikaricp.connections.acquire.percentile",
"tomcat.servlet.error",
"tomcat.servlet.request.max",
"jdbc.connections.max",
"tomcat.sessions.active.current",
"system.cpu.usage",
"tomcat.threads.busy",
"tomcat.threads.current",
"jvm.threads.peak",
"tomcat.global.request"
]
}

I am looking for the equivalent of Spring Boot 1 metrics value 'processors' in Spring Boot 2.

Does anyone know if this value is still available and under what name or if its been moved elsewhere or if it doesn't exist anymore.

1
Are looking for the metrics endpoint ? the spring-team has a nice [maven migration plugin] (github.com/spring-projects/spring-boot/wiki/…)Dirk Deyne
I have listed the contents of the metrics endpoint above. Using the names on the end of the url you get the metric result so, for example, localhost:8080/actuator/metrics/tomcat.global.request.max produces { "name": "tomcat.global.request.max", "measurements": [ { "statistic": "VALUE", "value": 7.007 } ], "availableTags": [ { "tag": "name", "values": [ "http-nio-8085" ] } ] } . I am looking for the equivalent of Spring Boot 1 metrics value 'processors' in Spring Boot 2.karen
I am looking for the equivalent of Spring Boot 1 metrics value 'processors' in Spring Boot 2 => localhost:8080/metrics/processorsDirk Deyne

1 Answers

1
votes

You are looking for a metric called system.cpu.count.

E.g. http://localhost:8080/actuator/metrics/system.cpu.count