Ruby Conf 2013 - New Ruby 2.1 Awesomeness: Fine-grained Object Allocation Tracing

Channel:
Subscribers:
42,400
Published on ● Video Link: https://www.youtube.com/watch?v=qzNNH2mnp08



Duration: 32:25
1,065 views
10


By Sam Rawlins

Ruby 2.1 is coming out soon with an amazing new feature under ObjectSpace: #trace_object_allocations. We are now able to trace the file and line number (as well as method) where any Ruby object is allocated from. This is a very welcome feature, as object-level tracing has been very difficult in Ruby, especially since the memprof gem could not support Ruby past 1.8.x.

This new Ruby 2.1 feature is really just exposing some raw (and vast) data, so it can be difficult to tease out meaningful information. Two gems are introduced in this talk to solve just that problem. The objspace-stats gem allows us to view and summarize new object allocations in meaningful ways. We'll look at how to filter, group, and sort new object allocations. The second gem is rack-objspace-stats. We'll see how this tool can intercept requests to a Rack stack, and measure new object allocations taking place during the request. (For those familiar, this works very similar to the rack-perftools_profiler gem.)

We'll look at various examples of how this new Ruby 2.1 feature, and these tools can help an organization reduce unnecessary memory allocations, and speed up their code, especially mature Rack applications.

Help us caption & translate this video!

http://amara.org/v/FG54/




Other Videos By Confreaks


2013-12-04Ruby Conf 2013 - The Future of JRuby by Charles Nutter and Thomas Enebo
2013-12-03Ruby Conf 2013 - Unleash the Secrets of the Standard Library with ...
2013-12-03Ruby Conf 2013 - How to control physical devices with mruby
2013-12-03Ruby Conf 2013 - The Big Picture by Jim Weirich
2013-12-03Ruby Conf 2013 - A Lightweight SOA Framework using Ruby, Apache Thrift and AMQP
2013-12-03Ruby Conf 2013 - Preferring Object-Orientation to Metaprogramming
2013-12-03Ruby Conf 2013 - Test Driven Neural Networks with Ruby by Matthew Kirk
2013-12-03Ruby Conf 2013 - Advanced Concurrent Programming in Ruby
2013-12-03Ruby Conf 2013 - Compilers For Free by Tom Stuart
2013-12-03Madison Ruby 2013 - Cats
2013-12-03Ruby Conf 2013 - New Ruby 2.1 Awesomeness: Fine-grained Object Allocation Tracing
2013-12-03Madison Ruby 2013 CLOSURE by Steve Klabnik
2013-12-03Ruby Conf 2013 - My KidsRuby Journey by PJ & Katie Hagerty
2013-12-03Ruby Conf 2013 - Arrrr me hearty! Sailing the Seas of DRb in a Shoe
2013-12-02Ruby Conf 2013 - "Bioruby"...understanding the intricacies of 'Life' using Ruby
2013-12-02Ruby Conf 2013 - Profiling Ruby: Finding 10x Gains In RSpec and CRuby
2013-12-02Ruby Conf 2013 - Object management on Ruby 2.1 by Koichi Sasada
2013-12-02Ruby Conf 2013 - Effective Debugging by Jonathan Wallace
2013-12-02Ruby Conf 2013 - REPL driven development with Pry by Conrad Irwin
2013-12-02Ruby Conf 2013 - A Peek Inside The Ruby Toolbox
2013-12-01Ruby Conf 2013 - Fault Tolerant Data: Surviving the Zombie Apocalypse