Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Live with Rails

Live with Rails

My life with Rails and how I avoid it.

975ff6c8166f6f32889f004a904ffa39?s=128

Oursky Limited

April 09, 2013
Tweet

Transcript

  1. Live with Rails And avoid Rails Rick Mak, Apr 2013

    Tuesday, 9 April, 13
  2. Fact Rails is fast on creating MVP Rails is fast

    on creating Restful API Rails has many stackoverflow articles. Tuesday, 9 April, 13
  3. Getting big and getting away Rails is slow Test is

    Rails is stupidly slow EdwinKwok says Rails is Architecture, not Entity: https://speakerdeck.com/oursky/ clean-code?slide=50 Tuesday, 9 April, 13
  4. Heaven & Hell Tuesday, 9 April, 13

  5. Requirement Both Project and User have quota Project may have

    owner If a project has owner, ignore project quota If a project owner quota exceed, consider project quota. User can upgrade his quota Tuesday, 9 April, 13
  6. Your Rails model Project User Project Quota User Quota Tuesday,

    9 April, 13
  7. Where is the Logic? Tuesday, 9 April, 13

  8. Fat ActiveRecords Tuesday, 9 April, 13

  9. ActiveSupport::Concern http://blog.codeclimate.com/blog/2012/10/17/7-ways- to-decompose-fat-activerecord-models/ “Any application with an app/concerns directory is

    concerning.” Tuesday, 9 April, 13
  10. No Time! I really need test case when it about

    $money$ I really need test case when I follow up fat AR. Tuesday, 9 April, 13
  11. No more free project Boss Tuesday, 9 April, 13

  12. Where to change Tuesday, 9 April, 13

  13. Standalone project payment Boss Tuesday, 9 April, 13

  14. My life Tuesday, 9 April, 13

  15. Introduce Quota Project Quota & User Quota is for storage

    only All logic belongs to Quota Tuesday, 9 April, 13
  16. Quota is not AR It test against its rspec, it

    is fast. One place to edit Tuesday, 9 April, 13
  17. Result Tuesday, 9 April, 13

  18. Architecture matters Around 5 ticket about resource protection against expire/archive/non-owner

    will become trivial to fix after introducing Quota. Rails architecture is just a guideline. Tuesday, 9 April, 13