Request Details

Route
/api_complex GET
Timestamp
Nov 11, 2026 8:13 AM
Duration
149.74 ms
Status
200
Response Size
71 KB
Error
No

Performance Breakdown

Database
15.1% (9 queries)
View Rendering
22.7%
Application Logic
62.1%
Other Operations
0.0%
Total Operations
24
Slowest Operation
149.74 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 301.2ms 602.4ms 903.5ms 1204.7ms

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
UPDATE posts SET view_count = view_count + ? WHERE published = ? 14 ms 9.3%
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 > ? 27 ms 18.0%
layouts/application 30 ms 20.0%
DELETE FROM posts WHERE id = ? 13 ms 8.7%
home/index 28 ms 18.7%
users/index 34 ms 22.7%
home#api_complex 150 ms 100.0%
INSERT INTO posts (user_id, title, content, published, created_at, updated_at) VALUES (?, ?, ?, ?, ?, ?) 10 ms 6.7%
home#api_complex 150 ms 100.0%
users/index 33 ms 22.0%
SELECT posts.* FROM posts WHERE title LIKE ? OR content LIKE ? 27 ms 18.0%
users/index 40 ms 26.7%
SELECT name FROM users 34 ms 22.7%
UPDATE posts SET title = ?, content = ?, updated_at = ? WHERE id = ? 33 ms 22.0%
home#api_complex 150 ms 100.0%
home/index 22 ms 14.7%
home#api_complex 150 ms 100.0%
layouts/application 19 ms 12.7%
users/index 25 ms 16.7%
posts/show 20 ms 13.4%
home#api_complex 150 ms 100.0%
layouts/application 23 ms 15.4%
SELECT * FROM posts WHERE user_id = ? ORDER BY created_at DESC LIMIT ? 15 ms 10.0%
SELECT * FROM posts WHERE user_id = ? ORDER BY created_at DESC LIMIT ? 9 ms 6.0%