Skip to content

Instantly share code, notes, and snippets.

@miloops
Created August 20, 2009 21:37
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save miloops/171408 to your computer and use it in GitHub Desktop.
Save miloops/171408 to your computer and use it in GitHub Desktop.
Rails 2.3 latest
| AR |
------------------------------------------------------------------
Model#id x100000 | 1.057 |
Model.new (instantiation) x10000 | 0.346 |
Model.new (setting attributes) x10000 | 0.967 |
Model.first x10000 | 3.932 |
Model.all limit(100) x1000 | 10.701 |
Model.all limit(100) with relationship x1000 | 25.143 |
Model.all limit(10,000) x10 | 10.925 |
Model.create x10000 | 34.254 |
Resource#attributes= x10000 | 1.047 |
Resource#update x10000 | 14.359 |
Resource#destroy x10000 | 22.425 |
Model.transaction x10000 | 3.065 |
==================================================================
Total | 128.220 |
Rails 3
| AR |
------------------------------------------------------------------
Model#id x100000 | 0.950 |
Model.new (instantiation) x10000 | 0.309 |
Model.new (setting attributes) x10000 | 0.946 |
Model.first x10000 | 5.780 |
Model.all limit(100) x1000 | 11.690 |
Model.all limit(100) with relationship x1000 | 23.125 |
Model.all limit(10,000) x10 | 11.205 |
Model.create x10000 | 34.797 |
Resource#attributes= x10000 | 1.399 |
Resource#update x10000 | 17.000 |
Resource#destroy x10000 | 29.333 |
Model.transaction x10000 | 2.478 |
==================================================================
Total | 139.010 |
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment