Skip to content

Commit

Permalink
chore: ignore 404 for prometheus
Browse files Browse the repository at this point in the history
  • Loading branch information
yashmehrotra committed May 23, 2024
1 parent ae1d44f commit 6b20ea0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions cmd/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,9 @@ func serve(ctx context.Context, configFiles []string) {
e.POST("/run/:id", scrapers.RunNowHandler)

e.Use(echoprometheus.NewMiddlewareWithConfig(echoprometheus.MiddlewareConfig{
Registerer: prom.DefaultRegisterer,
Skipper: telemetryURLSkipper,
Registerer: prom.DefaultRegisterer,
Skipper: telemetryURLSkipper,
DoNotUseRequestPathFor404: true,
}))

e.GET("/metrics", echoprometheus.NewHandlerWithConfig(echoprometheus.HandlerConfig{
Expand Down

0 comments on commit 6b20ea0

Please sign in to comment.