This project is archived and is in readonly mode.

#4866 ✓resolved
Jan De Poorter

Slow Development

Reported by Jan De Poorter | June 15th, 2010 @ 08:06 PM | in 3.0.2

A patch to improve speed in development, add descendents method to ActiveRecord::Base as suggested by Yehuda

Comments and changes to this ticket

  • Stephan Kaag
  • Wincent Colaiuta

    Wincent Colaiuta June 18th, 2010 @ 03:18 PM

    -1 please don't apply these patches in their current form.

    Patch 1/2 doesn't actually fix the spelling; it removes the correct spelling and inserts the wrong spelling.

    See:

    http://dictionary.reference.com/browse/descendant

    http://dictionary.reference.com/browse/descendent

    "descendent" is an adjective, so could be used to say something like "descendent_classes".

    "descendant" is a noun, which is what we need here.

  • Jeremy Kemper

    Jeremy Kemper June 18th, 2010 @ 11:59 PM

    • State changed from “new” to “open”

    Let's switch back to descendant

  • Santiago Pastorino

    Santiago Pastorino June 19th, 2010 @ 12:16 AM

    • Milestone cleared.
    • Assigned user changed from “Yehuda Katz (wycats)” to “José Valim”

    As requested by Jeremy, assigned to José.
    Also Wincent is right, so don't change the name, leave as descendants

  • José Valim

    José Valim June 19th, 2010 @ 11:20 PM

    • State changed from “open” to “resolved”

    I pushed a bunch of commits to solve this issue. Could you please try it out?

  • Jan De Poorter

    Jan De Poorter June 19th, 2010 @ 11:36 PM

    It still feels a lot slower then on beta4, yet benchmarks show that loading is a lot faster. Are there any good ways in Rails3 to profile a request?

    jan-wired:Openminds/sock (master*)$ r benchmarker 10 'User; ActionDispatch::Callbacks.new(Proc.new {}, false).call({})'
    /Users/jan/.bundle/ruby/1.8/gems/tolk-1.0/lib/tolk/engine.rb:5)
                user     system      total        real
    #1      0.840000   0.090000   0.930000 (  1.259372)
    
  • José Valim

    José Valim June 19th, 2010 @ 11:54 PM

    • State changed from “resolved” to “open”

    Jan, I'm almost sure that in the benchmark script above, most of the time is spent in loading the class User. Could you confirm? And the current results are two times slower than beta4, right?

  • Jan De Poorter

    Jan De Poorter June 20th, 2010 @ 12:10 AM

    Forget my last post, laptop was under lot of IO load which made results a bit off. With current master this is the result from the benchmark.

    jan-wired:Openminds/sock (master*)$ r benchmarker 10 'User; ActionDispatch::Callbacks.new(Proc.new {}, false).call({})'
    /Users/jan/.bundle/ruby/1.8/gems/tolk-1.0/lib/tolk/engine.rb:5)
                user     system      total        real
    #1      0.550000   0.020000   0.570000 (  0.585960)
    

    which is the same speed as with beta4, it's also the same speed when running through the app in a browser. Load times per page of 0.5seconds instead of 3 to 4seconds / request.

    Thanks a bunch, for me it is resolved

  • José Valim

    José Valim June 20th, 2010 @ 12:15 AM

    • State changed from “open” to “resolved”

    Great!

  • Jeremy Kemper

    Jeremy Kemper October 15th, 2010 @ 11:01 PM

    • Milestone set to 3.0.2
    • Importance changed from “” to “Low”

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

Attachments

Pages