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

Spinnakerを利用した自動カナリー分析 / Automated Canary Analysis by Spinnaker with Kayenta

Spinnakerを利用した自動カナリー分析 / Automated Canary Analysis by Spinnaker with Kayenta

Yoichiro Shimizu

July 27, 2018
Tweet

More Decks by Yoichiro Shimizu

Other Decks in Technology

Transcript

  1. Spinnakerを利用した
    自動カナリー分析
    8FCΤϯδχΞษڧձ
    :PJDIJSP4IJNJ[V!CVEPVHVNJ

    View full-size slide

  2. 自己紹介
    ‣ ਗ਼ਫཅҰ࿠!CVEPVHVNJ
    ‣ GSFFF,,
    ‣ #BDLFOE%FTLUPQ"QQFOHJOFFS
    ‣ (P3VCZPO3BJMT/&5
    ‣ ϒϩάIUUQCVEPVHVNJHJUIVCJP

    View full-size slide

  3. 今日のゴール
    ‣ ͳͥΧφϦʔϦϦʔεͷ෼ੳΛࣗಈԽ͍ͨ͠ͷ͔஌ͬͯ΋Β͏
    ‣ 4QJOOBLFSͱ,BZFOUBΛ࢖ͬͯԿ͕Ͱ͖Δͷ͔஌ͬͯ΋Β͏

    View full-size slide

  4. アジェンダ
    ‣ ΧφϦʔϦϦʔεͱ͸
    ‣ ͳͥΧφϦʔϦϦʔεͷ෼ੳΛࣗಈԽ͍ͨ͠ͷ͔ʁ
    ‣ 4QJOOBLFSͱ,BZFOUB
    ‣ ·ͱΊ

    View full-size slide

  5. 継続的デリバリー
    ‣ $POUJOVPVTEFMJWFSZ $%
    JTBTPGUXBSFFOHJOFFSJOHBQQSPBDIJO
    XIJDIUFBNTQSPEVDFTPGUXBSFJOTIPSUDZDMFT FOTVSJOHUIBUUIF
    TPGUXBSFDBOCFSFMJBCMZSFMFBTFEBUBOZUJNF
    ‣ IUUQTFOXJLJQFEJBPSHXJLJ$POUJOVPVT@EFMJWFSZ
    ‣ ϓϩμΫτΛ୹ظؒʹ͍ͭͰ΋ຊ൪؀ڥʹϦϦʔεͰ͖Δ͜ͱ

    View full-size slide

  6. カナリーリリース
    ‣ ϓϩμΫτ΍αʔϏεͷ৽ػೳΛҰ෦ϢʔβʔͷΈ͕ར༻Ͱ͖ΔΑ
    ͏ʹϦϦʔε͠ɺ৽ػೳʹ໰୊͕ͳ͍͜ͱΛ֬ೝ͠ͳ͕Βஈ֊తʹ
    શମʹ޲͚ͯల։͍ͯ͘͠σϓϩΠख๏ͷ͜ͱɻ
    ‣ IUUQTNBLJUBOJOFUTIJNBVNBDBOBSZSFMFBTF
    next version
    Production

    View full-size slide

  7. What’s next operation?
    ‣ ΧφϦʔϦϦʔεͷ݁ՌʹԠͨ࣍͡ͷखॱ͸ʁ
    ‣ ϩʔϧΞ΢τͯ͠શͯͷσϓϩΠϝϯτΛ৽όʔδϣϯʹ͢Δ
    ‣ ৽όʔδϣϯΛ࡟আͯ͠ݱߦόʔδϣϯͰϩʔϧόοΫ͢Δ
    ‣ ྑ͠ѱ͠͸Ͳ͏΍ͬͯ෼ੳ͢ΔʁͲ͏൑அ͢Δʁ
    ‣ ͕͜͜खಈͩͱ$%ͷࣗಈԽ్͕੾ΕΔ

    View full-size slide

  8. SpinnakerとKayentaで
    この問題を解決する

    View full-size slide

  9. Spinnaker
    ‣ IUUQTXXXTQJOOBLFSJP
    ‣ ܧଓతσϦόϦʔπʔϧɻLVCFSOFUFTରԠɻSFECMBDLEFQMPZ DIBPTNPOLFZͳͲ΋Մೳ
    ‣ 4QJOOBLFS͸ʮϤοτͷࡾ֯ൕʯͱ͍͏ҙຯ
    ‣ /FUqJY੡(PPHMF΋ڞಉ։ൃɻ೥ʹ044Խ
    ‣ $POUSJCVUPSʹ͸.JDSPTPGU΍0SBDMF΋ɻ
    ‣ ϚϧνΫϥ΢υରԠ
    ‣ "84 ($1 "[VSF ,VCFOFUFT
    ‣ 4QSJOHCPPUϑϨʔϜϫʔΫ +BWB(SPPWZ

    View full-size slide

  10. Spinnakerを利用した継続的デリバリー
    4UBHF/PUJpDBUJPO5SJHHFSΛ૊Έ߹Θͤͯ
    σϓϩΠύΠϓϥΠϯΛఆٛ͢Δ͜ͱ͕Ͱ͖Δ

    View full-size slide

  11. Kayenta
    ‣ 4QJOOBLFSͰ࢖͑ΔαϒϞδϡʔϧ
    ‣ "VUPNBUFE$BOBSZ"OBMZTJTBU/FUqJYXJUI,BZFOUB
    ‣ 4QJOOBLFSͱ,BZFOUBΛ͘Έ͋ΘͤΔ͜ͱͰΧφϦʔϦϦʔεͷࣗಈ෼ੳ͕Մೳ
    ‣ 4UBDLESJWFS$MPVEXBUDI%BUBEPHͷϝτϦΫεΛࣗಈతʹ෼ੳ
    ‣ ࣄલఆٛͨ͠ධՁ߲໨ͷ݁ՌͰϩʔϧΞ΢τϩʔϧόοΫΛܾఆ

    View full-size slide

  12. Kayenta
    σϓϩΠύΠϓϥΠϯʹࣗಈΧφϦʔϦϦʔε෼ੳεςʔδΛઃஔ
    4UBDLESJWFSͷϝτϦΫεঢ়ଶ͔Β৽όʔδϣϯΛࣗಈ෼ੳ͢Δ

    View full-size slide

  13. 自動カナリー分析の流れ

    View full-size slide

  14. ࠓճ͸($1Ͱ4UBDLESJWFSΛར༻ͨ͠ߏ੒
    next version
    Production
    1. Deploy
    2. Monitoring
    3. Scoring
    分析構成

    View full-size slide

  15. 1.メトリクス定義を事前に設定
    4UBDLESJWFSͰධՁ߲໨ʹ͍ͨ͠ϝτϦΫεΛఆ͓ٛͯ͘͠
    $16ෛՙͳͲ͸LTͷඪ४ϩά͔ΒऔಘՄೳ

    View full-size slide

  16. 2.分析設定を定義
    4QJOOBLFS্ͰΧφϦʔϦϦʔεͷධՁ߲໨Λఆٛ͢Δɻ
    ෳ਺߲໨Λ෼ੳର৅ʹͨ͠Γ֤߲໨ͷ΢ΣΠτ΋ઃఆՄೳ

    View full-size slide

  17. 3.Piplineで分析用のデプロイを定義
    ج४ͱͳΔݱߦWFSͱɺΧφϦʔϦϦʔε͢Δ৽WFSͷσϓϩΠΛఆٛ͢Δ

    View full-size slide

  18. 4.本番ロードバランサ配下に配置
    ج४ͱͳΔݱߦWFSͱɺ৽WFSͷσϓϩΠΛຊ൪ϩʔυόϥϯα഑Լʹ഑ஔ͢Δ

    View full-size slide

  19. 5.自動デプロイを実行
    ৽WFS͕ݱߦWFSΑΓධՁ݁Ռ͕ѱ͔ͬͨ৔߹ϩʔϧόοΫ͢Δ 1JQFMJOF͕ࣦഊ͢Δ

    ධՁ͕Α͔ͬͨΒͦͷ··࣍ͷ4UBHF͕࣮ߦ͞ΕɺϩʔϧΞ΢τ͢Δ

    View full-size slide

  20. 今日のゴール
    ‣ ͳͥΧφϦʔϦϦʔεͷ෼ੳΛࣗಈԽ͍ͨ͠ͷ͔஌ͬͯ΋Β͏
    ‣ 4QJOOBLFSͱ,BZFOUBΛ࢖ͬͯԿ͕Ͱ͖Δͷ͔஌ͬͯ΋Β͏

    View full-size slide

  21. まとめ
    ‣ ܧଓతσϦόϦʔͰ͸ΧφϦϦϦʔεޙͷϩʔϧΞ΢τ ϩʔϧόο
    Ϋʣ΋ࣗಈԽ͍ͨ͠
    ‣ 4QJOOBLFS,BZFOUBͰϝτϦΫεΛجʹࣗಈԽ
    ‣ σϓϩΠΛ҆શɾਝ଎ʹ͢Δ͜ͱͰ։ൃऀ͸։ൃʹूதͰ͖Δ

    View full-size slide