daily pastebin goal
76%
SHARE
TWEET

Untitled

a guest Sep 20th, 2013 135 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Sam Saffron / Jeff Atwood - Measuring Ruby - Discourse/StackOverflow
  2.  
  3. - Always be measuring (don't be "playing it blind")
  4. - Dtrace/Stap
  5.   - Added in Ruby 2.0
  6.   - Using Dtrace call samplers to track method invocation counts
  7. - rbtrace
  8.   - like strace but for ruby
  9.   - very awesome
  10. - manual patching for instrumentation
  11.   - old school
  12.   - precise/clean
  13. - rack-mini-profiler
  14.   - demo (see conference video)
  15.   - in depth debugging information for rack requests (SQL tracing, intermethod timing analysis)
  16.   - memory_profiler support for ruby-head (flamegraphs as well)
  17.     - flamegraphs are much more accurate now, more samples per runtime slice
  18.   - embedded callstack sampler in T*S_2
  19.   - exception performance is poor (0.3 ms per exception) non-local transfer of controls are slow -- rack-mini-profiler shows these
  20.   - require is expensive as well, 0.66 ms per require
  21. - improving dev speed
  22.   - traditional fix is to enable asset bundling in Dev, this compromises the dev experience
  23.   - why is this happening?
  24.     - assets are validated after a full middleware crawl
  25.       - etag calculation
  26.       - ....
  27.     - at discourse, shortcircuit this process w/ custom middleware (code in preso)
  28. - memory and ruby
  29.   - in ruby head, memory profiler is new
  30.   - CoW friendly GC lowers memory overhead
  31. - running benchmarks
  32.   - continuously and with new hooks it's much easier to implement
  33. - what can you do?
  34.   - audit memory usage
  35.   - run rack_mini_profiler to integrate performance metrics into dev and production
  36.   - Use flamegraphs to find your slowest code
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top