Fast & Scalable

Fast & Scalable

This is a presentation I gave at Hungry Academy on making a Rails App fast & scalable. Covers the Front and backend and talks about speed and throughput optimizations.

Db953d125f5cc49756edb6149f1b813e?s=128

Richard Schneeman

July 16, 2012
Tweet

Transcript

  1. 2.
  2. 5.
  3. 8.
  4. 13.
  5. 28.
  6. 33.
  7. 36.
  8. 37.

    Problem @products = Product.all # ... <% @products.each do |product|

    %> <li><%= product.name %></li> <li>$<%= product.price %></li> <li><%= product.user.name %></li> ...
  9. 38.
  10. 40.

    Solved @products = Product.includes(:user).all # ... <% @products.each do |product|

    %> <li><%= product.name %></li> <li>$<%= product.price %></li> <li><%= product.user.name %></li> ...
  11. 41.
  12. 43.
  13. 47.
  14. 72.
  15. 73.
  16. 74.
  17. 75.
  18. 80.

    Amazon (AWS) Provision instances & use chef or other tools

    to install proper software, and then connect to a load balancer
  19. 84.
  20. 85.
  21. 89.

    Master DB Slave DB Slave DB Slave DB Slave DB

    Write Copy Read Master/Slave
  22. 95.
  23. 108.

    Riak Distributed B C A Eventual Consistency D Data In

    Copied To Extra Nodes ... Eventually
  24. 115.
  25. 116.

    CDN

  26. 121.
  27. 123.
  28. 124.

    CDN

  29. 132.
  30. 145.
  31. 146.
  32. 159.
  33. 160.