HackerTube
HomeLongsLikedHistoryWatch laterCategoriesPlaylistsSettings

RailsConf 2011: Aaron Patterson, "Double Dream Hands: So Intense!"

O'Reilly1 HN recommender · recommended in 1 month, 2011-2012
YouTube
26K views · 15 years ago · talk · dated

Aaron Patterson's RailsConf 2011 talk on Rails 3.1 performance, showing why deeper Rack middleware stacks slow Rails and how a shallower pipeline helps. It also touches on Rack API design.

Cited in Rails performance and Rack design discussions for Patterson's analysis of stack depth and garbage collection.

Python, Ruby & scripting languagesSoftware performance & optimizationWeb development#rails#rack#ruby#middleware#aaronpatterson

5 comments from Hacker News

@jonsmock2012 · in “Why your web framework should not adopt Rack API”

Nice article, Jose! For those interested, Aaron Patterson (tenderlove) talks about this in his RailsConf talk, starting at 26:45. ▶ this video

CitesView on HN
@getsat2011 · in “Rails master is now 4.0.0.beta; Ruby 1.8.7 support dropped”

As the number of Rack middleware pieces in a base Rails app grows, it gets slower. MRI and YARV spend a lot more time doing GC as the stack depth grows. Aaron Patterson mentioned that he was working on a modification to the Rack API where each piece of middleware did not call the next piece, reducing the stack depth and drastically improving the runtime performance of Rails apps. Here's the video where he talks about it (towards the beginning): ▶ this video

CitesView on HN
@getsat2011 · in “CoderTalk - Episode 5. Has Rails Lost It's Rails? Slow Rails Test, etc.”

In Aaron Patterson's recent "Double Dream Hands: So Intense!" presentation[0], he came to the conclusion that Rails 3's slowness is because MRI sucks at GC on a deep stack depth. The average stack depth of Rails 3 applications is ENORMOUS. He mentions in the video that he rewrote the Rack API to pass a mutated var to the next piece of middleware in the Rack chain instead of calling the next middleware and passing an env var to it. The gains were pretty impressive. Hopefully, they make this change to the Rack API for Rails 3.2. That change + the 1.9.3 fix for requiring files[1] should result in much faster overall Rails performance. [0] ▶ this video [1] link

CitesView on HN
@maercsrats2011 · in “Rails 3.1.0 to be released on 22nd August”

There is a talk by Aaron Patterson from RailsConf talking about why rails 3.1 is slower than rails 3 and rails 2.3. Basically the rack pipeline is getting deeper. Because rack is so simplistic every request requires you going through that pipeline and back again. His solution is to break up the pipeline into 3 separate types: generators, filters (for response data), and lifecycle hooks. Doing this brought the speed back up to rails 2.3 speeds and a bit faster in some instances. But those were early numbers. You can see his talk here: ▶ this video The interesting stuff happens around the 20 min. mark. Overall, there are a lot of people who want to make ruby better and faster. Rubinius, Jruby and MacRuby are all examples. There are also people who want to make Rails faster. They are examining the slower parts (active record, rack, etc) and working to make it better.

RecommendsView on HN
@mdasen2011 · in “Ask HN: Where is the Django community?”

I don't want to be defending the OP's position, but. . . settings.py is a mess. Even Simon's written a post bashing it ( link ). I cringe a little starting up a project and having to dive into the settings.py file. In some ways, Django tries to be flexible, but it's clumsy. For example, you can have your templates in your app directories. So, you have /path/to/project/posts/templates and /path/to/project/people/templates. However, you can't just put your templates in there because Django doesn't namespace them. Like, if I do {% extends "people/base.html" %} it will look in both those template directories for a people folder. It won't be like, "oh, I should look in /path/to/project/people/templates/base.html". I have to put the template in /path/to/project/people/templates/people/base.html. That's clumsy. urls.py is another flexible/clumsy thing (IMO). Django wants me to write a regexp for the simple cases. It's kludgy to do r'^people/(?P<id>\d+)/?$' just to have a URL with an ID in it. And other frameworks have been able to offer the power of regexps for the case where you want them while making the common cases a lot easier. Django caches certain things and if you try to change it at runtime, well, it doesn't change. Django's reusable apps aren't that reusable. They were a lot more reusable than Rails' apps, but the Rails team has worked on that a lot - especially with 3.1 and how each app can have its own assets (images/css/js) all namespaced and neat and tidy. There isn'

CitesView on HN
How to Speed up a Python Program 114,000 times.59:11

How to Speed up a Python Program 114,000 times.

InfoQ
171K views • 13 years ago
Progressive Performance (Chrome Dev Summit 2016)35:42

Progressive Performance (Chrome Dev Summit 2016)

Chrome for Developers
34K views • 9 years ago
RailsConf 2016 - Rails to Phoenix by Brian Cardarella28:34

RailsConf 2016 - Rails to Phoenix by Brian Cardarella

Confreaks
12K views • 10 years ago
Yehuda Katz - Why Rails is Hard (Railsberry 2012)53:12

Yehuda Katz - Why Rails is Hard (Railsberry 2012)

applicake
29K views • 14 years ago
RailsConf 2016 -  Turbolinks 5: I Can’t Believe It’s Not Native! by Sam Stephenson37:37

RailsConf 2016 - Turbolinks 5: I Can’t Believe It’s Not Native! by Sam Stephenson

Confreaks
61K views • 10 years ago
Understanding the Python GIL46:10

Understanding the Python GIL

David Beazley
127K views • 14 years ago
Mojo Lang - Tomorrow's High Performance Python? (with Chris Lattner)1:24:39

Mojo Lang - Tomorrow's High Performance Python? (with Chris Lattner)

Developer Voices
64K views • 2 years ago
CppCon 2014: Chandler Carruth "Efficiency with Algorithms, Performance with Data Structures"1:13:41

CppCon 2014: Chandler Carruth "Efficiency with Algorithms, Performance with Data Structures"

CppCon
235K views • 12 years ago
The Truth about Rust/WebAssembly Performance29:47

The Truth about Rust/WebAssembly Performance

Greg Johnston
218K views • 3 years ago
High Performance Web Sites and YSlow1:00:34

High Performance Web Sites and YSlow

Google TechTalks
90K views • 18 years ago
Chris Seaton @ VMSS16: JRuby+Truffle: Why it’s Important to Optimise the Tricky Parts1:02:44

Chris Seaton @ VMSS16: JRuby+Truffle: Why it’s Important to Optimise the Tricky Parts

softdevteamuk
5K views • 10 years ago
'Fastware' - Andrei Alexandrescu [ ACCU 2016 ]1:02:17

'Fastware' - Andrei Alexandrescu [ ACCU 2016 ]

ACCU Conference
34K views • 10 years ago
RailsConf 2015 - Nothing is Something35:53

RailsConf 2015 - Nothing is Something

Confreaks
84K views • 11 years ago
React.js Conf 2015 - Hype!31:17

React.js Conf 2015 - Hype!

Meta Developers
108K views • 11 years ago
High-performance Tree Wrangling, the APL Way // Aaron Hsu // Dyalog '1830:37

High-performance Tree Wrangling, the APL Way // Aaron Hsu // Dyalog '18

Dyalog User Meetings
6K views • 7 years ago
RailsConf 2014 - Keynote: Writing Software by David Heinemeier Hansson1:01:17

RailsConf 2014 - Keynote: Writing Software by David Heinemeier Hansson

Confreaks
123K views • 12 years ago
October CincyRb - Jim Weirich on Decoupling from Rails1:15:58

October CincyRb - Jim Weirich on Decoupling from Rails

Launch Scout
48K views • 13 years ago
Data-Oriented Demo: SOA, composition1:32:47

Data-Oriented Demo: SOA, composition

Jonathan Blow
201K views • 11 years ago
A 10x faster TypeScript13:45

A 10x faster TypeScript

Microsoft Developer
608K views • 1 year ago
Speed Up Your JavaScript56:23

Speed Up Your JavaScript

Google TechTalks
136K views • 17 years ago