Demo: finding a slow endpoint's hot spot with JFR
On This Lesson 3 topics
This lesson is planned. The outline below lists the topics it will cover. The full lesson has not been published yet.
In this lesson
locate and fix a planted CPU hot spot; prepares MID-008-LAB1.
Draft outline details
Step by step
- Reproduce:
/orders/reporthas p95 of 900 ms under load. - Record 2 minutes with JFR (profile settings) during the load test.
- In JMC, Method Profiling and flame graph: find the dominant frame (a regex compiled on every call).
- Hypothesis: precompile the pattern. Change only that.
- Planned mistake: "optimize" a different method that looked suspicious in code review. Show it was 1% of samples. Fix: follow the profile.
- Re-measure under the same load; p95 drops; record before/after in the log.
Practice
Apply this lesson with the module's lab, exercises and quiz.
Marking a lesson complete is optional and you can undo it any time. Your progress stays in this browser.