Re: [prometheus-users] questions about testing patterns and metric registration in Go

2020-04-14 Thread Victor Watkins
:44, Victor Watkins wrote: > > > > I get your point about comparing a simple counter to a logger and not > needing > > to put that under test. Thanks, that sanity-checks an opinion I had > already > > formed. But suppose we're writing an exporter and that is our core l

Re: [prometheus-users] questions about testing patterns and metric registration in Go

2020-04-04 Thread Victor Watkins
UTC-6, Brian Brazil wrote: > > On Sat, 4 Apr 2020 at 00:27, Victor Watkins > wrote: > >> Hi! This question is about best practices for testing applications that >> use client_golang to instrument with custom metrics and avoiding the >> dreaded "duplicate

[prometheus-users] questions about testing patterns and metric registration in Go

2020-04-03 Thread Victor Watkins
Hi! This question is about best practices for testing applications that use client_golang to instrument with custom metrics and avoiding the dreaded "duplicate metrics collector registration attempted". Let's say I have an HTTP handler for an app that keeps a counter. The counter can be page hi