Bird
0
0

What output will you get when you access the /metrics endpoint if the application is running normally?

medium📝 component behavior Q5 of 15
Spring Boot - Actuator
What output will you get when you access the /metrics endpoint if the application is running normally?
AAn HTML page listing all endpoints
BA JSON object with various performance metrics like CPU and memory usage
CPlain text showing the application version
DA JSON object showing database schema details
Step-by-Step Solution
Solution:
  1. Step 1: Understand the /metrics endpoint purpose

    /metrics provides performance and resource usage data in JSON format.
  2. Step 2: Eliminate incorrect outputs

    Application version is shown by /info, HTML page listing endpoints is not default, and database schema is not shown by /metrics.
  3. Final Answer:

    A JSON object with various performance metrics like CPU and memory usage -> Option B
  4. Quick Check:

    /metrics shows performance data = A JSON object with various performance metrics like CPU and memory usage [OK]
Quick Trick: /metrics returns JSON with performance stats [OK]
Common Mistakes:
  • Expecting HTML output
  • Confusing /metrics with /info
  • Thinking it shows database details

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Spring Boot Quizzes