prometheus / exporter-toolkit

Utility package to build exporters
Apache License 2.0
262 stars 79 forks source link

Provide option to start webserver using slog #239

Closed ArthurSens closed 5 days ago

ArthurSens commented 2 weeks ago

Slog was added to the Go standard libraries as an alternative for structured logging. A lot of tools are trying to migrate to slog, aiming to remove their dependency tree in third-party libraries like go-kit

A few examples:

exporter-toolkit still requires go-kit in its contructor: https://github.com/prometheus/exporter-toolkit/blob/61beb2cb9c212dc4423a13aa5d1abdaf047e87f1/web/tls_config.go#L30 https://github.com/prometheus/exporter-toolkit/blob/61beb2cb9c212dc4423a13aa5d1abdaf047e87f1/web/tls_config.go#L287

Would it make sense to provide another one with slog?

SuperQ commented 2 weeks ago

The other proposal I had was that we make a breaking change here that we just convert this over to slog and drop go-kit.

Depends on how much work it is to support a second option.

SuperQ commented 5 days ago

We decided to go with the breaking change. This is now released.