webhook
webhook copied to clipboard
prometheus metrics
Anyone tried to add prometheus metrics/integration yet? Speaking anything against it?
I assume you mean exposing a metrics HTTP endpoint in webhook for prometheus to scrape.
I haven't looked into it, but I've only toyed with prometheus in the past. Not super-familiar with it. I would be open to adding it, but we may need to agree on a proposal first. My initial questions:
- How would the user configure the feature? Do we need #326 first?
- What metrics should we export? Would that be configurable? What Caddy does looks interesting.
Yes Caddy came to my mind too. Personally I'm mostly interested in the error- and over-all-counts and less in the details like timings ... but that's just me.
On the configuration. I came across a lot of implementations where no config other than on/off were possible - thought small scale things. Most are using /metrics as the endpoint anyways and turning the feature on an off by providing a port or not through a flag. That said having config files could make things easier.
I've implemented prometheus metrics libraries mostly with python and my golang-fu isn't that strong but I'm hoping to help as much as I can.