What is the difference between an exporter and instrumenting your app directly? [Basic]
Answer
An exporter exposes metrics from an external system or runtime, while direct instrumentation adds metrics inside the application code. Exporters are good for infrastructure and third-party systems; direct instrumentation is better for business and service-level behavior.
Technical explanation
Exporters can show Redis memory, node CPU, or database connection stats, but they cannot know that a checkout failed due to a payment validation rule.
Direct instrumentation captures domain-specific metrics such as orders_created_total, payment_authorization_duration_seconds, and business error classes.
A strong observability design uses both exporter metrics and application metrics.
Hands-on example
Hands-on: use redis_exporter for cache hit ratio and memory fragmentation. Instrument the checkout application directly for checkout_attempts_total, checkout_success_total, and dependency latency. Alert on checkout SLO first, then use Redis exporter metrics for diagnosis.
Check how well your resume matches the role with our free resume checker— match score, ATS check, and the skills you're missing.
More Observability interview questions
- What is the Pushgateway, and why is it discouraged for most cases? [Basic]
- What is a scrape target, and how does service discovery find them? [Basic]
- What is PromQL, and what is an instant vector versus a range vector? [Basic]
- How does Prometheus collect metrics — what is the pull model and scraping? [Basic]
- What is the difference between rate() and irate()? [Basic]
- What is the difference between a counter and a gauge? [Basic]
- How do you compute a 95th percentile latency from a histogram in PromQL (histogram_quantile)? [Basic]
- What are the Prometheus metric types (counter, gauge, histogram, summary)? [Basic]