PCA Service Discovery & Configuration Flashcards
6 cards from real PCA practice questions. Tap to flip, then mark Knew It or Still Learning โ missed cards come back until you master them.
Read the first 6 PCA Service Discovery & Configuration flashcards as text
What does the `__address__` label represent in Prometheus target discovery?
Answer: The host:port used to scrape the target
`__address__` holds the `host:port` that Prometheus uses to construct the scrape URL for a target.
Which Prometheus SD config discovers targets by querying DNS SRV records?
Answer: dns_sd_config
`dns_sd_config` resolves DNS A, AAAA, or SRV records on a configurable refresh interval to discover scrape targets.
What Prometheus relabeling action copies a source label value into a new label name?
Answer: replace
The `replace` action (the default) copies a matched source label value (optionally transformed by regex) into a target label.
Which relabeling action renames all labels matching a regex by applying a replacement pattern to their names?
Answer: labelmap
`labelmap` applies the regex to all label *names* and renames matching labels according to the replacement pattern, useful for promoting meta-labels.
What is the role of the `__metrics_path__` label in Prometheus scrape targets?
Answer: Specifies the HTTP path Prometheus requests to collect metrics
`__metrics_path__` overrides the default `/metrics` HTTP path for a specific target, allowing non-standard exposition endpoints.
In Prometheus HTTP service discovery (`http_sd_config`), what must the HTTP endpoint return?
Answer: A JSON array of target groups with labels
`http_sd_config` expects the endpoint to return a JSON array of target group objects, each with a `targets` list and optional `labels` map.