Request Details

Route
/api_complex GET
Timestamp
Sep 09, 2026 11:37 PM
Duration
168.06 ms
Status
201
Response Size
40 KB
Error
No

Performance Breakdown

Database
6.1% (3 queries)
View Rendering
26.0%
Application Logic
67.9%
Other Operations
0.0%
Total Operations
13
Slowest Operation
168.06 ms

Request Trace

How to read this

Each row is a layer of your stack. Many short Database bars means N+1 queries — fix with includes(). A wide Action bar with little Database time means slow Ruby code. A wide View bar usually means a partial rendered in a loop.

Action
View
Database
Other
Action
View
Database
0.0ms 185.5ms 371.1ms 556.6ms 742.2ms

Operations

How to use this

Sort by Impact to find your biggest wins. Click any row for details and optimisation suggestions. The same SQL appearing multiple times is an N+1 — fix with includes(). A single operation above 50% impact is your highest priority.

Operation Duration Impact Timeline Actions
home#api_complex 168 ms 100.0%
home#api_complex 168 ms 100.0%
home#api_complex 168 ms 100.0%
SELECT * FROM comments WHERE post_id = ? ORDER BY created_at DESC LIMIT ? 10 ms 6.0%
layouts/application 28 ms 16.7%
SELECT * FROM comments WHERE post_id = ? ORDER BY created_at DESC LIMIT ? 18 ms 10.7%
SELECT DISTINCT users.*, posts.*, comments.* FROM users, posts, comments WHERE users.id = posts.user_id AND posts.id = comments.post_id AND users.created_at > ? AND posts.created_at > ? AND comments.created_at > ? 17 ms 10.1%
home/index 23 ms 13.7%
users/index 23 ms 13.7%
home/index 40 ms 23.8%
users/index 26 ms 15.5%
layouts/application 35 ms 20.8%
posts/show 18 ms 10.7%