PCA (Prometheus Certified Associate) sample exam question with answer 82

Question:
What is a Prometheus exporter?

  1. A program that exposes metrics from a system that does not natively expose Prometheus metrics
  2. A program that sends metrics to Prometheus
  3. An application directly instrumented with Prometheus metrics
  4. A code library that allows exposing Prometheus metrics
Answer:
A - Exporters
B - is incorrect as applications do not send metrics directly to Prometheus. Some applications may push metrics to the Prometheus Pushgateway which Prometheus then scrapes, but that still is not an exporter.
C - is incorrect as such an application would not require use of an exporter.
D - this is the definition of a Prometheus client library