何故マイクロサービスにするんだっけ? #WEM14 / Why Microservices?

何故マイクロサービスにするんだっけ? #WEM14 / Why Microservices?

2019/08/30 WEBエンジニア勉強会での発表資料です。

5dbaf4015e7f249ab21b195ced8e9e46?s=128

Masatoshi Tada

August 30, 2019
Tweet

Transcript

  1. 1.

    (C) CASAREAL, Inc. All rights reserved. 8&. ԿނϚΠΫϩαʔϏεʹ ͢ΔΜ͚ͩͬʁ ג

    ΧαϨΞϧଟాਅහ ೥݄೔ 8&#ΤϯδχΞษڧձ 1
  2. 2.

    (C) CASAREAL, Inc. All rights reserved. 8&. ͜ͷηογϣϯʹ͍ͭͯ ▸ ͜͜ʙ೥΄ͲͰϚΠΫϩαʔϏε͸


    Ұؾʹ޿·Γ·ͨ͠ɻ ▸ Ͱ΋ɺͦ΋ͦ΋ԿͷͨΊʹϚΠΫϩαʔϏεʹ
 ͢ΔΜͰ͚ͨͬ͠ʁ ▸ ʮͦ΋ͦ΋ʯΛৼΓฦͬͯΈ·͠ΐ͏ɻ 2
  3. 3.

    (C) CASAREAL, Inc. All rights reserved. 8&. ࣗݾ঺հ ▸ ଟాਅහʢ!TVLF@NBTBʣ

    ▸ ݚमτϨʔφʔ!ΧαϨΞϧ ▸ 4QSJOH+BWB&&.JDSPTFSWJDFT
 $MPVE'PVOESZ,VCFSOFUFT ▸ 1JWPUBMೝఆߨࢣ ▸ ೔ຊ4QSJOHϢʔβձελοϑ 3
  4. 5.

    (C) CASAREAL, Inc. All rights reserved. 8&. ϚΠΫϩαʔϏεͷݚमɺ΍ͬͯ·͢ ▸ 1JWPUBMೝఆ4QSJOH$MPVE%FWFMPQFS

    ▸ /FUqJY044ʷ4QSJOH$MPVEʹΑΔ
 ϚΠΫϩαʔϏε։ൃΛशಘͰ͖Δʂ ▸ 4FSWJDF%JTDPWFSZɺ$MJFOU4JEFMPBE#BMBODJOHɺ
 $JSDVJU#SFBLFSɺ%JTUSJCVUFE5SBDJOHɺ0"VUIʜ ▸ ೔ؒ 5
  5. 7.

    (C) CASAREAL, Inc. All rights reserved. 8&. ໨࣍ ᶃ ϚΠΫϩαʔϏεͬͯԿ͚ͩͬʁ

    ᶄ ԿނϚΠΫϩαʔϏεʹ͢ΔΜ͚ͩͬʁ ᶅ ϚΠΫϩαʔϏεʹ͢Δ࣌ʹɺ
 ؾΛ͚ͭͳ͖Ό͍͚ͳ͍͜ͱͬͯԿ͚ͩͬʁ 7
  6. 8.

    (C) CASAREAL, Inc. All rights reserved. 8&. ໨࣍ ᶃ ϚΠΫϩαʔϏεͬͯԿ͚ͩͬʁ

    ᶄ ԿނϚΠΫϩαʔϏεʹ͢ΔΜ͚ͩͬʁ ᶅ ϚΠΫϩαʔϏεʹ͢Δ࣌ʹɺ
 ؾΛ͚ͭͳ͖Ό͍͚ͳ͍͜ͱͬͯԿ͚ͩͬʁ 8
  7. 9.

    (C) CASAREAL, Inc. All rights reserved. 8&. ϞϊϦγοΫͳΞϓϦέʔγϣϯ ▸ ͭͷΞϓϦέʔγϣϯʹ


    શͯͷػೳؚ͕·Ε͍ͯΔ ▸ ʮϞϊϦεʯͱ΋ݺ͹ΕΔ 9 ΞϓϦέʔγϣϯ ػೳ" ػೳ# ػೳ$ ػೳ%
  8. 10.

    (C) CASAREAL, Inc. All rights reserved. 8&. .4 ϚΠΫϩαʔϏε ▸

    ෳ਺ͷϚΠΫϩαʔϏε͕
 ࿈ܞ͠߹͏͜ͱͰɺ
 γεςϜશମΛߏ੒͢Δ ▸ ϚΠΫϩαʔϏεؒͷ௨৴͸ɺ
 )551΍ϝοηʔδϯάͰߦ͏ 10 .4 .4 .4
  9. 11.

    (C) CASAREAL, Inc. All rights reserved. 8&. ϚΠΫϩαʔϏεͷఆٛ ʁ 11

    l-PPTFMZDPVQMFETFSWJDFPSJFOUFEBSDIJUFDUVSF
 XJUICPVOEFEDPOUFYUTz "ESJBO$PDLDSPGU "84 FY/FUqJY ʮڥք෇͚ΒΕͨίϯςΩετʹΑΔɺ
 ɹૄ݁߹ͳαʔϏεࢦ޲ΞʔΩςΫνϟͰ͋Δʯ
  10. 13.

    (C) CASAREAL, Inc. All rights reserved. 8&. <࠶ܝ>ϚΠΫϩαʔϏεͷఆٛ ʁ 13

    l-PPTFMZDPVQMFETFSWJDFPSJFOUFE BSDIJUFDUVSFXJUICPVOEFEDPOUFYUTz "ESJBO$PDLDSPGU "84 FY/FUqJY ʮڥք෇͚ΒΕͨίϯςΩετʹΑΔɺ
 ɹૄ݁߹ͳαʔϏεࢦ޲ΞʔΩςΫνϟͰ͋Δʯ
  11. 14.

    (C) CASAREAL, Inc. All rights reserved. 8&. ϚΠΫϩαʔϏε͕ؒૄ݁߹ͳͷ͕ॏཁ ▸ ͋ΔϚΠΫϩαʔϏεΛมߋͯ͠΋ɺ


    ผͷϚΠΫϩαʔϏεʹ͸Өڹ͕ແ͍ͷ͕ཧ૝ ▸ ϚΠΫϩαʔϏεʹ͢Ε͹
 ඞͣૄ݁߹ʹͳΔ༁Ͱ͸ͳ͍ͷͰ஫ҙ ▸ ˠৄࡉ͸࣍ষ΁ 14
  12. 15.

    (C) CASAREAL, Inc. All rights reserved. 8&. ໨࣍ ᶃ ϚΠΫϩαʔϏεͬͯԿ͚ͩͬʁ

    ᶄ ԿނϚΠΫϩαʔϏεʹ͢ΔΜ͚ͩͬʁ ᶅ ϚΠΫϩαʔϏεʹ͢Δ࣌ʹɺ
 ؾΛ͚ͭͳ͖Ό͍͚ͳ͍͜ͱͬͯԿ͚ͩͬʁ 15
  13. 17.

    (C) CASAREAL, Inc. All rights reserved. 8&. ϞϊϦε͸සൟͳվળ͕೉͍͠ ▸ ΞϓϦέʔγϣϯ͕େ͖͍ͨΊɺιʔείʔυ

    ͷมߋʹΑΔӨڹൣғͷௐࠪʹ͕͔͔࣌ؒΔ ▸ ͭͷػೳ͚ͩΛվળ͍ͨ࣌͠Ͱ΋ɺ
 શػೳΛఀࢭͯ͠࠶σϓϩΠ͢Δඞཁ͕͋Δ
 ˠ෦ॺؒௐ੔͕ඞཁͩͬͨΓʜ 17 ٯʹݴ͑͹ɺසൟͳมߋ͕ෆཁͳΒ ϚΠΫϩαʔϏεʹ͢Δඞཁແ͠
  14. 18.

    (C) CASAREAL, Inc. All rights reserved. 8&. ϚΠΫϩαʔϏε͸සൟͳվળ͕͠΍͍͢ ▸ ΞϓϦέʔγϣϯ͕খ͍ͨ͞Ίɺιʔείʔυ

    ͷมߋʹΑΔӨڹൣғͷௐࠪʹ͕͔͔࣌ؒΒͳ ͍ ▸ ͭͷػೳ͚ͩΛվળ͍ͨ࣌͠͸ɺ
 ػೳ͚ͩఀࢭͯ͠࠶σϓϩΠ͢Ε͹Α͍
 ˠ෦ॺؒௐ੔΋ෆཁ 18
  15. 19.

    (C) CASAREAL, Inc. All rights reserved. 8&. ʮͦ͏Ͱ͖ΔΑ͏ʹ࡞Δʯ͜ͱ͕ॏཁ ▸ ϚΠΫϩαʔϏεʹ͢Ε͹ඞͣ

    ▸ मਖ਼Өڹൣғʹ͕͔͔࣌ؒΒͳ͍ ▸ ଞͷػೳʹؔ܎ͳ͘σϓϩΠͰ͖Δ ▸ ͦ͏Ͱ͖ΔΑ͏ʹ࡞Δ͜ͱ͕ॏཁʂʂʂʂ 19 ༁Ͱ͸ͳ͍ʂʂ
  16. 20.

    (C) CASAREAL, Inc. All rights reserved. 8&. ϝϦοτͳͷ͔ʁ ▸ ϚΠΫϩαʔϏε͝ͱʹ


    ࣗ༝ʹݴޠ΍ϑϨʔϜϫʔΫΛબ୒Ͱ͖Δ
 ˠޙʑͰอक͕େม͡Όͳ͍ʁ 20
  17. 21.

    (C) CASAREAL, Inc. All rights reserved. 8&. ໨࣍ ᶃ ϚΠΫϩαʔϏεͬͯԿ͚ͩͬʁ

    ᶄ ԿނϚΠΫϩαʔϏεʹ͢ΔΜ͚ͩͬʁ ᶅ ϚΠΫϩαʔϏεʹ͢Δ࣌ʹɺ
 ؾΛ͚ͭͳ͖Ό͍͚ͳ͍͜ͱͬͯԿ͚ͩͬʁ 21
  18. 22.

    (C) CASAREAL, Inc. All rights reserved. 8&. ো֐͕ى͖΍͘͢ͳΔ ▸ Քಇ཰͸ֻ͚ࢉతʹ௿Լ

    ʷ˺  ▸ μ΢ϯͨ͠ΒࣗಈͰ࠶ىಈ͢ΔΑ͏ͳϓϥοτϑΥʔϜ͕
 ඞཁ ▸ ϚΠΫϩαʔϏεؒ͸ωοτϫʔΫ ▸ ʮ෼ࢄίϯϐϡʔςΟϯάͷམͱ݀͠ʯͰݕࡧ ▸ ো֐ͷ఻೻͕ى͖΍͘͢ͳΔ ▸ $JSDVJU#SFBLFSͰ๷͕ͳ͍ͱʜ 22 ※ 0.1% ≒ 8࣌ؒ46෼ / ೥
  19. 23.

    (C) CASAREAL, Inc. All rights reserved. 8&. ٕज़త೉қ౓͸ඈ༂తʹ্͕Δ ▸ ૬खͷϚΠΫϩαʔϏεʹো֐͕ى͖͍ͯΔ͜ͱલఏͰ࡞Δ

    ▸ 4FSWJDF%JTDPWFSZɺ$JSDVJU#SFBLFSɺʜ ▸ ϩά΋෼ࢄ͢ΔͷͰҰՕॴʹू໿ͯ͠෼ੳ͢Δ ▸ &MBTUJDTFBSDIɺ-PHTUBTIɺ,JCBOBɺ1SPNFUIFVTɺ(SBGBOBɺ;JQLJOɺʜ ▸ සൟʹมߋɾσϓϩΠ͢ΔͷͰɺࣗಈςετ΍$*$%͸ඞਢ ▸ Y6OJUɺ4FMFOJVNɺ+FOLJOTɺʜ ▸ ଟछଟ༷ͳϓϥοτϑΥʔϜ΍ϛυϧ΢ΣΞΛ׆༻͢Δ ▸ 1BB4,VCFSOFUFTɺ%PDLFSɺ"QBDIF,BGLBɺ3FEJTɺʜ 23
  20. 24.

    (C) CASAREAL, Inc. All rights reserved. 8&. ͓͕͔͔ۚΔ ▸ Ϋϥ΢υΠϯϑϥඅ

    ▸ 7.΍ίϯςφͷ਺͕ඈ༂తʹ૿͑Δ ▸ Ϋϥ΢υͷϚωʔδυαʔϏεͷར༻͕૿͑Δ ▸ ਓ݅අ ▸ ྫʣສԁਓ݄ʷਓνʔϜʷνʔϜ
 ʹສԁ݄ 24
  21. 25.

    (C) CASAREAL, Inc. All rights reserved. 8&. Ͳ͜Ͱ෼ׂ͢Ε͹ૄ݁߹ʹͳΔͷʁ ▸ ʮڥք෇͚ΒΕͨίϯςΩετͰ෼ׂͤΑʯ

    ▸ ͓લ͸ԿΛʢ͈́ ▸ ্ख͘෼ׂ͠ͳ͍ͱɺมߋ͕ϞϊϦεΑΓେมʹͳΔ ▸ ϚΠΫϩαʔϏεΛ·͕ͨͬͯมߋ͠ͳ͚Ε͹ͳΒͳ͍ʢ෼ࢄϞϊϦεʣ ▸ ੈͷதͰ΋౴͑͸ग़͍ͯͳ͍ͱ͍͏ͷ͕චऀͷݟղ ▸ ߟ͑Δώϯτˠ૿ా͞ΜͷεϥΠυ ▸ ϚΠΫϩαʔϏεͭͷ෼ׂΞϓϩʔν
 IUUQTXXXTMJEFTIBSFOFUNBTVEBTT 25
  22. 27.