grafana / unused

CLI tool, Prometheus exporter, and Go module to list your unused disks in all cloud providers
Apache License 2.0
51 stars 1 forks source link

Pass down logger to providers #42

Open inkel opened 1 year ago

inkel commented 1 year ago

In #41 we've found an issue when a GCP disk doesn't contain JSON in its Description field, failing the program. As an MVP solution we discussed to log the error instead of failing and continue processing disks, however, in order to do that we should pass a logger to gcp.Provider so we don't depend on a global variable, which are bad.

After further analysis it also surfaces that we probably want all providers to have access to a logger too.