Skip to content

Commit b2da7c8

Browse files
authored
chore: do not use path in metric labels if response code is 404 not found. (PostHog#28020)
1 parent 1e7949a commit b2da7c8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

livestream/main.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,8 @@ func main() {
9494
e.Use(middleware.GzipWithConfig(middleware.GzipConfig{
9595
Level: 9, // Set compression level to maximum
9696
}))
97-
e.Use(echoprometheus.NewMiddleware("livestream"))
97+
e.Use(echoprometheus.NewMiddlewareWithConfig(
98+
echoprometheus.MiddlewareConfig{DoNotUseRequestPathFor404: true, Subsystem: "livestream"}))
9899

99100
e.Use(middleware.CORSWithConfig(middleware.CORSConfig{
100101
AllowOrigins: []string{"*"},

0 commit comments

Comments
 (0)