Request Details

Route
/api_complex GET
Timestamp
Nov 18, 2026 11:38 AM
Duration
120.72 ms
Status
201
Response Size
58 KB
Error
No

Performance Breakdown

Database
18.6% (12 queries)
View Rendering
22.5%
Application Logic
59.0%
Other Operations
0.0%
Total Operations
25
Slowest Operation
120.72 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 255.9ms 511.8ms 767.7ms 1023.6ms

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/index 28 ms 23.2%
SELECT * FROM posts WHERE title LIKE ? AND content LIKE ? AND LOWER(title) LIKE ? AND UPPER(content) LIKE ? 5 ms 4.1%
home#api_complex 121 ms 100.0%
layouts/application 33 ms 27.3%
SELECT users.* FROM users LEFT JOIN posts ON users.id = posts.user_id LEFT JOIN comments ON posts.id = comments.post_id WHERE users.active = ? AND posts.published = ? AND comments.approved = ? OR users.created_at > ? AND posts.created_at > ? AND commen... 7 ms 5.8%
SELECT * FROM comments WHERE post_id = ? ORDER BY created_at DESC LIMIT ? 21 ms 17.4%
home#api_complex 121 ms 100.0%
SELECT * FROM posts WHERE title LIKE ? AND content LIKE ? AND LOWER(title) LIKE ? AND UPPER(content) LIKE ? 4 ms 3.3%
users/index 23 ms 19.1%
home#api_complex 121 ms 100.0%
SELECT id, name, email FROM users WHERE id = ? 16 ms 13.3%
home/index 21 ms 17.4%
SELECT name FROM users 20 ms 16.6%
posts/show 16 ms 13.3%
home#api_complex 121 ms 100.0%
SELECT COUNT(*) FROM comments WHERE post_id = ? 22 ms 18.2%
SELECT * FROM posts WHERE created_at > ? 26 ms 21.5%
SELECT * FROM comments WHERE post_id = ? ORDER BY created_at DESC LIMIT ? 23 ms 19.1%
layouts/application 31 ms 25.7%
posts/show 40 ms 33.1%
SELECT * FROM posts WHERE created_at > ? 14 ms 11.6%
SELECT * FROM posts WHERE user_id = ? ORDER BY created_at DESC LIMIT ? 12 ms 9.9%
home#api_complex 121 ms 100.0%
SELECT COUNT(*) FROM comments WHERE post_id = ? 20 ms 16.6%
users/index 38 ms 31.5%