14 Apr 2023 04:32 PM - last edited on 20 Apr 2023 12:59 PM by Ana_Kuzmenchuk
Hi, I want to see specific metrics in Dynatrace from Spring Boot app.
For example:
So I read that there is something that can be done with Micrometer.
What's really unclear to me is why I would want to use Micrometer at all if my metrics are already exposed through Spring metrics?
Solved! Go to Solution.
14 Apr 2023 05:37 PM
Hi @BenoitSigouin,
Maybe you should try to collect them via jmx. For hikari it should work.
Available hikari metrics in this system:
ActiveConnections
ConnectionTimeout
IdleConnections
IdleTimeout
LeakDetectionThreshold
MaximumPoolSize
MaxLifetime
MinimumIdle
ThreadsAwaitingConnection
TotalConnections
ValidationTimeout
I hope it helps.
Best regards,
Mizső
14 Apr 2023 10:49 PM
Collecting the metrics using JMX has two caveats:
On the other way - Micrometer metric ingest will allow the application to send metrics directly with already proper dimensions and context to Dynatrace with zero configuration.
I prefer the approach when application sends the metrics. Applications are aware of the metrics they have and should send them without needing to configure the metrics collection in Dynatrace (or any other monitoring tool).
17 Apr 2023 02:21 PM
So we have to do so with micrometer ? ever since spring boot use out of the box metrics within on oh its own module (spring metrics) ?
17 Apr 2023 04:11 PM
@BenoitSigouin SpringBoot2 and SpringBoot3 use SpringBoot Actuator which uses Micrometer and it can be used directly with the Dynatrace Micrometer integration. So if you have SpringBoot>2.6 you just include the dependency (dynatrace micrometer registry) to get the metrics automatically out from SpringBoot actuator. If you have your own application metrics in your Spring Boot application, you should have them exposed using Micrometer API anyway.
16 Apr 2023 06:42 AM
Hi @Julius_Loman,
What is the DDU consumption of this solution? Can be deducted it form the included 1000 metrics per full stack host in case of OA ingestion?
Thanks in advance.
Mizső
16 Apr 2023 03:38 PM
@Mizső it's just as another ingested metric. Yes, it counts towards the 1000 metrics per full stack host unit. It really depends on the application being monitored. Sure it might cost some DDUs, but the automation is really worth it. The only drawback I see is the fact, that such ingested metrics are not yet automatically displayed on the process group screens.
With the upcoming unified analysis screens for services, I can see big potential when using the metrics with Davis Causal Correlation Analysis.