Request Details

Route
/api_complex GET
Timestamp
Nov 22, 2026 6:24 AM
Duration
249.18 ms
Status
201
Response Size
69 KB
Error
No

Performance Breakdown

Database
8.6% (7 queries)
View Rendering
9.9%
Application Logic
81.4%
Other Operations
0.0%
Total Operations
21
Slowest Operation
249.18 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 382.5ms 765.0ms 1147.4ms 1529.9ms

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
posts/show 39 ms 15.7%
home/index 9 ms 3.6%
users/index 13 ms 5.2%
home#api_complex 249 ms 100.0%
users/index 14 ms 5.6%
SELECT posts.* FROM posts WHERE title LIKE ? OR content LIKE ? 17 ms 6.8%
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 > ? 33 ms 13.2%
SELECT posts.* FROM posts WHERE title LIKE ? OR content LIKE ? 2 ms 0.8%
home#api_complex 249 ms 100.0%
posts/show 5 ms 2.0%
home#api_complex 249 ms 100.0%
SELECT * FROM posts WHERE user_id = ? ORDER BY created_at DESC LIMIT ? 26 ms 10.4%
home#api_complex 249 ms 100.0%
home/index 9 ms 3.6%
posts/show 15 ms 6.0%
SELECT name FROM users 21 ms 8.4%
SELECT * FROM comments WHERE post_id = ? ORDER BY created_at DESC LIMIT ? 18 ms 7.2%
home#api_complex 249 ms 100.0%
posts/show 20 ms 8.0%
posts/show 28 ms 11.2%
SELECT * FROM posts WHERE title LIKE ? AND content LIKE ? AND LOWER(title) LIKE ? AND UPPER(content) LIKE ? 15 ms 6.0%