Skip to content

Commit

Permalink
feat: Tolerate collector failures
Browse files Browse the repository at this point in the history
Signed-off-by: Jan-Otto Kröpke <[email protected]>
  • Loading branch information
jkroepke committed Nov 24, 2024
1 parent 0494727 commit 60039f0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cmd/windows_exporter/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ func main() {
}

func run() int {
startTime := time.Now()

app := kingpin.New("windows_exporter", "A metrics collector for Windows.")

var (
Expand Down Expand Up @@ -229,7 +231,7 @@ func run() int {
mux.HandleFunc("GET /debug/pprof/trace", pprof.Trace)
}

logger.Info("Starting windows_exporter",
logger.Info(fmt.Sprintf("starting windows_exporter in %s", time.Since(startTime)),
slog.String("version", version.Version),
slog.String("branch", version.Branch),
slog.String("revision", version.GetRevision()),
Expand Down

0 comments on commit 60039f0

Please sign in to comment.