File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change 469
469
end
470
470
```
471
471
472
+ Active Record logs will also include timing info for the duration of how long
473
+ the main thread had to wait to access the result. This timing is useful to know
474
+ whether or not it' s worth to load the query asynchronously.
475
+
476
+ ```
477
+ DEBUG -- : Category Load (62. 1ms) SELECT * FROM ` categories` LIMIT 50
478
+ DEBUG -- : ASYNC Post Load (64ms) (db time 126. 1ms) SELECT * FROM ` posts` LIMIT 100
479
+ ```
480
+
481
+ The duration in the first set of parens is how long the main thread was blocked
482
+ waiting for the results, and the second set of parens with " db time" is how long
483
+ the entire query took to execute.
484
+
472
485
* Jean Boussier *
473
486
474
487
* Implemented ` ActiveRecord::Relation#excluding` method.
You can’t perform that action at this time.
0 commit comments