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

Migrate or shim BBE logger arguments to slog #1238

Open
nadiamoe opened this issue Mar 7, 2025 · 0 comments
Open

Migrate or shim BBE logger arguments to slog #1238

nadiamoe opened this issue Mar 7, 2025 · 0 comments

Comments

@nadiamoe
Copy link
Member

nadiamoe commented Mar 7, 2025

In https://redirect.github.com/prometheus/blackbox_exporter/pull/1311, BBE switched to slog, and that is blocking us from upgrading it:

Run make build-native
Building github.com/grafana/synthetic-monitoring-agent/cmd/synthetic-monitoring-agent (linux-amd64)
# github.com/grafana/synthetic-monitoring-agent/internal/prober/grpc
internal/prober/grpc/grpc.go:46:62: cannot use logger (variable of interface type logger.Logger) as *slog.Logger value in argument to bbeprober.ProbeGRPC
# github.com/grafana/synthetic-monitoring-agent/internal/prober/tcp
internal/prober/tcp/tcp.go:46:61: cannot use logger (variable of interface type logger.Logger) as *slog.Logger value in argument to bbeprober.ProbeTCP
# github.com/grafana/synthetic-monitoring-agent/internal/prober/http
internal/prober/http/http.go:65:62: cannot use logger (variable of interface type logger.Logger) as *slog.Logger value in argument to bbeprober.ProbeHTTP
make: *** [/__w/synthetic-monitoring-agent/synthetic-monitoring-agent/scripts/make/build.mk:21: build-go-linux-amd64-github.com/grafana/synthetic-monitoring-agent/cmd/synthetic-monitoring-agent] Error 1
Error: Process completed with exit code 2.

We should either move to slog, or somehow shim our existing logger into slog for BBE to accept it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant