question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`http_client_requests_seconds` Prometheus metrics missing with `retry` enabled

See original GitHub issue

Looks like when retry is enabled for the Prometheus does not return the http_client_requests_seconds metric for the configured client

Description

The stack we are using is SpringBoot 2.6.8, Riptide 3.2.2 and Kotlin/target Java 17 (eclipse-temurin), GET operation on the client. With this configuration:

factoring-service:
      base-url: https://xxx.zalan.do/
      tracing:
        tags:
          peer.service: factoring-service
      retry:
        enabled: true
        fixed-delay: 10 milliseconds
        max-retries: 1

The prometheus actuator doesn’t return the http_client_requests_seconds metric (for other clients without retry everything is fine). While disabling it, so with just:

factoring-service:
      base-url: https://xxx.zalan.do/
      tracing:
        tags:
          peer.service: factoring-service

Everything is fine.

Expected Behavior

http_client_requests_seconds is returned in any case, when the client operation is called.

Actual Behavior

http_client_requests_seconds is missing for the client configured with retry enabled, while it is returned for all the other clients

Steps to Reproduce

  • Configure a project with the previous stack (defined at the beginning of the description)
  • Configure 2 clients, one with retry and another without
  • Verify, after calling the client operations, that only for one of them the metric http_client_requests_seconds is available.

Context

Upgrade SpringBoot/Riptide/JDK in the project

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:10

github_iconTop GitHub Comments

1reaction
whiskeysierracommented, Jul 6, 2022

For reference, this is the issue for micrometer: https://github.com/micrometer-metrics/micrometer/issues/877

0reactions
gianvitomcommented, Jun 23, 2022

Ok, thank you. I will try to use your suggestion 👍

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spring Boot default metrics - Tom Gregory
Each outbound endpoint gets a http_client_requests_seconds metric. It comprises two metrics exposed by the /actuator/prometheus endpoint:.
Read more >
http_client_requests_seconds_c...
I am trying to enable Prometheus endpoint in my springboot project having below dependencies. SpringBoot version:
Read more >
Default metrics in Spring Boot (don't be that guy) - YouTube
In this video you'll discover how to enable all of this with a few lines of ... and graph them with tools like...
Read more >
Configuration - Prometheus.io
A configuration reload is triggered by sending a SIGHUP to the Prometheus process or sending a HTTP POST request to the /-/reload endpoint...
Read more >
How to troubleshoot remote write issues in Prometheus
A breakdown of all the metrics and configurations that can help you diagnose a remote write issue in Prometheus.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found