Skip to content

feat(metrics): add django prometheus#805

Merged
filippomc merged 1 commit into
developfrom
CH-193-CH-Django-add-Prometheus-custom-metrics
May 29, 2025
Merged

feat(metrics): add django prometheus#805
filippomc merged 1 commit into
developfrom
CH-193-CH-Django-add-Prometheus-custom-metrics

Conversation

@zsinnema

@zsinnema zsinnema commented May 28, 2025

Copy link
Copy Markdown
Contributor

Closes CH-193

adds django-prometheus to CH

@zsinnema zsinnema requested a review from filippomc May 28, 2025 12:26

@filippomc filippomc left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I'd only change the endpoint to be /metrics


urlpatterns = []

urlpatterns.append(path('prometheus/', include('django_prometheus.urls')))

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Usually /metrics is used, it's a kind of convention I'd follow also here

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe adding also the endpoint to the GK white listed by default will make life easier

Environment :: Web Environment
Framework :: Django
Framework :: Django :: 3.2
Framework :: Django :: 3.0.7

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this? We are on django 5 actually

@filippomc filippomc merged commit d6c2fbf into develop May 29, 2025
4 of 7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants