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

Prometheus Effect suspension #2370



None yet
3 participants
Copy link

commented Jan 22, 2019

Fixes #2367

Registration is not happening in an effect and can throw if it double registered for the same metric.

Copy link

left a comment

Test failure is legit. It broke a tut.

Spirit of it looks good.

@@ -62,7 +62,7 @@ object Prometheus {
* * @param prefix a prefix that will be added to all metrics
def apply[F[_]](registry: CollectorRegistry, prefix: String = "org_http4s_server")(
implicit F: Sync[F]): MetricsOps[F] =
implicit F: Sync[F]): F[MetricsOps[F]] = Sync[F].delay {

This comment has been minimized.

Copy link

rossabaker Jan 24, 2019


Could just call F.delay here... it already has a name.

Test failure is resolved

Copy link

left a comment

I like @aeons' suggestion. 👍 after that.

Update to use F directly
Co-Authored-By: ChristopherDavenport <>

@aeons aeons merged commit 3ead64c into http4s:master Feb 4, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.