What is the minimum requirement for an application to expose Prometheus metrics?
A.
It must be exposed to the Internet.
B.
It must be compiled for 64-bit architectures.
C.
It must be able to serve text over HTTP.
D.
It must run on Linux.
The Answer Is:
C
This question includes an explanation.
Explanation:
Prometheus collects metrics byscraping an HTTP endpointexposed by the target application. Therefore, theonly essential requirementfor an application to expose metrics to Prometheus is that itserves metrics in the Prometheus text exposition format over HTTP.
This endpoint is conventionally available at /metrics and provides metrics in plain text format (e.g., Content-Type: text/plain; version=0.0.4). The application can run on any operating system, architecture, or network — as long as Prometheus can reach its endpoint.
It doesnotneed to be Internet-accessible (it can be internal) and isnot limited to Linuxor any specific bitness.