15万人の作家を支えるサービス開発の裏側 / back-of-the-service-development-to-support-150000-creators

15万人の作家を支えるサービス開発の裏側 / back-of-the-service-development-to-support-150000-creators

「minne」技術戦略カンファレンスの資料です
https://www.youtube.com/watch?v=uYti3xbCVBQ

Cd3d2cb2dadf5488935fe0ddaea7938a?s=128

monochromegane

October 24, 2015
Tweet

Transcript

  1. 15ສਓͷ࡞ՈΛࢧ͑Δ αʔϏε։ൃͷཪଆ minneࣄۀ෦ ϓϥοτϑΥʔϜνʔϜ GMO Pepabo, Inc

  2. MIYAKE Yusuke @monochromegane

  3. Platform Team

  4. Fukuoka

  5. Web application Infrastructure and

  6. Ձ஋ʹ࣌ؒΛ࢖͏

  7. ΞλϦϚΤΛ ΞλϦϚΤʹ

  8. Infrastructure Team Development

  9. νʔϜͷΞλϦϚΤ

  10. ౰ࣄऀҙࣝΛ࣋ͯΔ

  11. ΍Δؾͷ໰୊΍Ζ͏΋Μʁ ஫ɿ΍Δؾͷ໰୊Ͱ͸ͳ͍Ͱ͔͢ʁ

  12. ౰ࣄऀҙࣝΛҭͯΔ

  13. ໨తͷڞ༗ Kickoff Break- down Daily stand-up MTG • શһࢀՃ •

    ϓϩδΣΫτͷ໨తΛڞ༗ • ΑΓΑ͍ղܾࡦͷݕ౼
  14. શମ૾ͷڞ༗ Kickoff Break- down Daily stand-up MTG λεΫ΁ͷམ͠ࠐΈ

  15. ਐḿͷڞ༗ Kickoff Break- down Daily stand-up MTG ظݶͱ༏ઌॱҐ

  16. ج൫ͷΞλϦϚΤ

  17. ن໛Λҙࣝͤ͞ͳ͍

  18. minne Client App Load Balancer Data Store OKARA CDN Job

    Worker Batch Memcached Search Request Image Request Dynamic Image Transformation Cache Data Job Job Job Data Indexing Notification Search
  19. Infrastructure as Code

  20. Puppet Packer Serverspec

  21. Deployment

  22. Don’t miss it !

  23. ։ൃͷΞλϦϚΤ

  24. γϯϓϧʹอͭ

  25. Code LOC 2012/01 2,662

  26. Code LOC 2013/01 5,508 2,662

  27. Code LOC 2014/01 7,984 2,662 5,508

  28. Code LOC 2015/01 12,085 2,662 5,508 7,984

  29. Code LOC 2015/10 15,771 2,662 5,508 7,984 12,085

  30. Rails

  31. • Ruby 2.2.3 • Rails 4.2.4

  32. • RailsͷϨʔϧʹ৐Γଓ͚Δ

  33. Microservices

  34. ػೳΛγϯϓϧʹอͭ

  35. • ಛԽͨ͠αʔϏεಋೖʹΑΔૣظ՝୊ղܾ • αʔϏε෼ׂʹΑΔػೳɾϊ΢ϋ΢ͷڞ༗

  36. Solr • ࡞Ոͱ࡞඼ͷݕࡧػೳ • Solr 4 (master-slave) + sunspot Master

    Slave App Job Worker Update item Indexing Job Indexing Replication Search
  37. OKARA • ࡞඼ը૾ͷಈతը૾αΠζม׵ • Nginx + ngx_small_light + ngx_mruby +

    CDN OKARA CDN Image Request Dynamic Image Transformation ngx_mruby • URL transformation • Hash validation ngx_small_light
  38. See also https://speakerdeck.com/yano3/dynamic-image-transformation-server-okara-beta https://speakerdeck.com/mizor/better-search-for-minne-with-ruby-and-solr @mizor minneͷݕࡧΛRubyͱSolrͰͪΐͬͱศརʹͨ͠࿩ @yano3 ngx_small_lightͱngx_mrubyͰ࡞Δಈతը૾ม׵αʔό

  39. CI

  40. ςετΛγϯϓϧʹอͭ

  41. Multi-containers CI test-queue worker test-queue worker test-queue master docker MySQL

    test-queue worker Docker in Docker Drone • Drone + RSpec + test-queue • Docker in Docker • 27min -> 8min
  42. ϨϏϡʔΛγϯϓϧʹอͭ

  43. Coding rule spec it do default, $stdout = $stdout, StringIO.new

    begin status = RuboCop::CLI.new.run(['--lint', file]) unless status.zero? raise "status: #{status}\n" + $stdout.string end ensure $stdout = default end end • Rubocop CLI • Ruby, Slim
  44. Next ΞλϦϚΤ

  45. • ϓϩδΣΫτେن໛Խ΁ͷରԠ • ۀ຿ϩδοΫෳࡶԽ΁ͷରԠ

  46. ΞλϦϚΤΛ ΞλϦϚΤʹ

  47. ͓ΘΓ