Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regression in v4.0.0 : Micrometer's gauges return no values for PoolStats #1726

Closed
ghusta opened this issue Jan 25, 2021 · 3 comments · Fixed by octawizard/padles-api#32, enonic/lib-sql#28, navikt/fplos#871 or navikt/fptilbake#1253

Comments

@ghusta
Copy link

ghusta commented Jan 25, 2021

Since v4.0.0, Micrometer's gauge metrics return no value.

For example, when using a Prometheus implementation, we will get NaN :

hikaricp_connections_active{application="my-demo-webapp",pool="HikariPool-1",} NaN
hikaricp_connections_idle{application="my-demo-webapp",pool="HikariPool-1",} NaN

I checked, there is no regression with PrometheusMetricsTracker, only with MicrometerMetricsTracker.

This kind of problem is referenced by the Micrometer documentation as :

At first sight, it seems to be related to this commit, which should be (partially) reverted in my opinion : 6e0f4a8

ghusta added a commit to ghusta/HikariCP that referenced this issue Jan 25, 2021
@brettwooldridge
Copy link
Owner

brettwooldridge commented Jan 25, 2021

@ghusta This issue with that commit being the problem is that, as my linter pointed out, that private poolStats member is referenced nowhere inside of the class. So, it's removal cannot be responsible for any behavioral change. Still investigating ... possibly related to the Prometheus related changes.

Nevermind, just read the referenced link. Apparently this was fixed some time ago with a contributed commit and message Maintain strong reference to PoolStats for Micrometer gauges (#1108). Would have been nice if the code had included a comment to that effect...

@brettwooldridge
Copy link
Owner

Fixed, release publishing in ~30min.

@ghusta
Copy link
Author

ghusta commented Jan 25, 2021

OK, thanks !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment