Skip to content

Commit

Permalink
add group_path param to config
Browse files Browse the repository at this point in the history
  • Loading branch information
evstratbg authored May 28, 2024
1 parent 0b27f37 commit 259a73d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions litestar/contrib/prometheus/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ class PrometheusConfig:
middleware_class: type[PrometheusMiddleware] = field(default=PrometheusMiddleware)
"""The middleware class to use.
"""
group_path: bool = field(default=False)
"""Whether to group paths in the metrics ot avoid cardinality explosion.
"""

@property
def middleware(self) -> DefineMiddleware:
Expand Down

0 comments on commit 259a73d

Please sign in to comment.