hn.today

Native Prometheus Integration with Nginx

categorica.io9 points0 comments
Screenshot of Native Prometheus Integration with Nginx

Categorica has open-sourced nginx-stats-prometheus, an NGINX module that exposes Prometheus metrics directly from the server instead of running a separate exporter web service or sidecar container. The team argues that a separate process adds deployment complexity and leaves the metrics collector itself outside the monitoring system. The module offers a simpler option for deployments that prefer native collection, though it is not intended as a full replacement for the established NGINX Prometheus Exporter.

The module is built against NGINX source and requires a C99 compiler and supporting libraries; existing NGINX installations need compatibility and stub-status features enabled. After installation, a configuration directive exposes a chosen endpoint such as /metrics. Available measurements include process status and ID, HTTP request and response counts, traffic by status class, method and protocol, request duration histograms, and connection statistics. It also reports basic per-server and per-upstream totals after traffic reaches them. Collection starts at process launch, but shared memory defaults to 1 MB, supports at most 512 server or upstream directives, and may silently skip metrics if memory runs out. The project is MIT-licensed and accepts reviewed contributions, but offers no support guarantee. Its trade-offs are fewer metrics, a required rebuild when NGINX changes, and less testing and maturity.

Read on categorica.io0 comments on Hacker News

Summary generated by AI from the linked article. hn.today is not affiliated with Hacker News or Y Combinator.

More in Web

The daily digest

Today's best Hacker News stories, summarized and screenshotted, one email a day.