$30 off During Our Annual Pro Sale. View Details »

LambdaとDynamoDBでIoTバックエンド開発

 LambdaとDynamoDBでIoTバックエンド開発

昔話したものを置いておく

okmttdhr

May 26, 2021
Tweet

More Decks by okmttdhr

Other Decks in Technology

Transcript

  1. -BNCEBͱ%ZOBNP%#Ͱ *P5όοΫΤϯυ։ൃ

  2. -BNCEBͱ%ZOBNP%#Ͱ *P5όοΫΤϯυ։ൃ ͍Ζ͍Ζͳʮ͜ΕͲ͏ͯ͠Δͷʁʯ Λ͝ڞ༗͠·͢ʂ ࠓ೔ͷςʔϚ

  3. ʮ͜ΕͲ͏ͯ͠Δͷʁʯ w 4FSWFSMFTTΞϓϦέʔγϣϯͷ؅ཧ w %ZOBNP%#ςʔϒϧઃܭ w %ZOBNP%#τϥϯβΫγϣϯ w .2555PQJDઃܭ w

    -BNCEBͷ؂ࢹ
  4. w ͍ΘΏΔݟकΓεϐʔΧʔͷΑ͏ͳػೳ w Ոʹஔ͘*P5εϐʔΧʔ w ϞόΠϧΞϓϦଆ͔Βϝοηʔδొ࿥ w σόΠεଆͰਓײηϯαʔϝοηʔδ࠶ੜ w ֎ग़࣌ͷϦϚΠϯμʔ΍ఱؾ༧ใͷઃఆͳͲ΋

    w ϞόΠϧΞϓϦͰϢʔβʔ؅ཧ΍Ϗʔίϯ؅ཧ΋Ͱ͖Δ ػೳཁ݅ w ϞόΠϧΞϓϦͱ௨৴͢Δ8FC"1* w "84*P5͔Β.255Ͱͭͳ͙όοΫΤϯυ
  5. ઃܭ֓ཁ ΤϯδχΞ͸ਓͰ ൒೥͘Β͍։ൃ͍ͯ͠·͢💦

  6. 4FSWFSMFTTΞϓϦέʔγϣϯͷ؅ཧ

  7. 4FSWFSMFTTΞϓϦέʔγϣϯͷ؅ཧ w Ϗϧυ w ύοέʔδ w σϓϩΠ w ςετ w

    ։ൃɾεςʔδϯάɾϓϩμΫγϣϯͳͲͷ؀ڥ؅ཧ w -BNCEBҎ֎ͷؔ࿈Ϧιʔε؅ཧ w ֤Ϧιʔε΁ͷద੾ͳϩʔϧ؅ཧ w ؀ڥม਺ Ұൠతͳ8FCΞϓϦέʔγϣϯͳͲͰߦ͏͜ͱ ʴ4FSWFSMFTTͰͷΈߦ͏͜ͱ
  8. "844".

  9. "844".ʹ͍ͭͯ w -BNCEBΛ࢖ͬͨ4FSWFSMFTTΞϓϦέʔγϣϯΛ؅ཧͰ͖ΔϞσϧ w ˞࣮ଶ͸$MPVE'PSNBUJPO w ͍Ζ͍Ζ͍͍ײ͡ʹ΍ͬͯ͘ΕΔ w େখؔΘΒͣଞͷҊ݅Ͱͷ࣮੷ɾ஌ݟ͕͋Δ w

    "844".Ͱ࢝ΊΔαʔόʔϨεΞϓϦέʔγϣϯ։ൃIUUQT XXXTMJEFTIBSFOFU:PTIJEB4IJOHPHFUUJOHTUBSUFEXJUIBXTTBN w αʔόʔϨεͳόοΫΞοϓγεςϜΛ"844".Λ༻͍ͯγϡοͱߏங ͢ΔΫοΫύου։ൃऀϒϩάIUUQTUFDIMJGFDPPLQBEDPNFOUSZ ɹ
  10. ઃܭ֓ཁ

  11. ͦͷଞɺ༷ʑͳϦιʔεΛ"844".Ͱ؅ཧ

  12. "844".Ͱ·͔ͳ͑ͳ͍෦෼͸ผϦϙδτϦͷ$MPVE'PSNBUJPOͰ؅ཧ

  13. -BNCEBؔ਺Λ࡞Δͨͼʹ"844". $MPVE'PSNBUJPO ͷ ઃఆΛॻ͘ඞཁ͕͋ͬͯେม ݱࡏɺҎ্ͷ-BNCEBؔ਺͕͋Δ w ઃఆ͠๨ΕͨΓʜ w λΠϙͨ͠Γʜ w

    શͯͷؔ਺ʹͻͱͭͣͭڞ௨ͷϓϨϑΟοΫεΛ෇͚ͨΓʜ
  14. UFNQMBUFZNMͷࣗಈੜ੒ ྫ"1*ͷ3PVUFTΛಡΈࠐΉ

  15. UFNQMBUFZNMͷࣗಈੜ੒ ྫ$MPVE'PSNBUJPOςϯϓϨʔτʹม׵͢Δ

  16. UFNQMBUFZNMͷࣗಈੜ੒ ྫ$MPVE'PSNBUJPOςϯϓϨʔτʹม׵͢Δ

  17. ϏδωεϩδοΫʹूதͰ͖Δ☺ w (PݴޠͰϝλϓϩάϥϛϯάIUUQTCMPHNNNDPSQDPKQCMPH NFUBHP

  18. %ZOBNP%#ͷςʔϒϧઃܭ

  19. %ZOBNP%#ͷϕετϓϥΫςΟε IUUQTEPDTBXTBNB[PODPNKB@KQBNB[POEZOBNPECMBUFTU EFWFMPQFSHVJEFCFTUQSBDUJDFTIUNM جຊతʹ͜Εʹै͑͹0,

  20. ࢀߟهࣄ👇 w αʔόʔϨεΞϓϦέʔγϣϯ޲͖ͷ%#ઃܭϕετϓϥΫςΟεIUUQT XXXTMJEFTIBSFOFU"NB[PO8FC4FSWJDFT+BQBOEC w 4FSWFSMFTTΛۃΊΔͨΊʹ%ZOBNP%#σʔλϞσϦϯάΛۃΊΑ͏ IUUQTTQFBLFSEFDLDPNNBSDZUFSVJMFUTCFDPNFUIFNBTUFSPG EZOBNPECEBUBNPEFMJOHUPCFDPNFUIFNBTUFSPGTFSWFSMFTT w "QQ4ZODΛ࢖͍͜ͳͨ͢Ίͷ%ZOBNP%#ઃܭύλʔϯIUUQT

    TQFBLFSEFDLDPNLUTVLBHPBQQTZODXPTIJ JLPOBTVUBNFGBMTFEZOBNPECTIFKJQBUBO w "84#MBDL#FMU0OMJOF4FNJOBS"NB[PO%ZOBNP%#IUUQT XXXTMJEFTIBSFOFU"NB[PO8FC4FSWJDFT+BQBOCMBDL CFMUEZOBNPEC SFGIUUQNBSDZIBUFOBCMPHDPNFOUSZ 
  21.  3%#෩ʹϦϨʔγϣφϧͳ&3ਤΛॻ͘  ΞΫηεύλʔϯΛྻڍ  %ZOBNP%#ͷεΩʔϚʹམͱ͠ࠐΉ ςʔϒϧઃܭͷେ·͔ͳखॱ

  22. 3%#෩ʹϦϨʔγϣφϧͳ&3ਤΛॻ͘

  23. ΞΫηεύλʔϯΛྻڍ IUUQTTQFBLFSEFDLDPNNBSDZUFSVJMFUTCFDPNFUIFNBTUFSPG EZOBNPECEBUBNPEFMJOHUPCFDPNFUIFNBTUFSPGTFSWFSMFTT

  24. ΞΫηεύλʔϯΛྻڍ

  25. %ZOBNP%#ͷεΩʔϚʹམͱ͠ࠐΉ ྫ͑͹ݕࡧ ΞΫηεύλʔϯ ϑΟϧλ৚݅ ͝ͱʹϨίʔυΛͭ͘Δ w ͢΂ͯͷ߲໨ͷҰཡදࣔ w Ϣʔβʔ໊ʹΑΔฒͼସ͑ɺϝʔϧΞυϨεʹΑΔݕࡧ w

    ϝʔϧΞυϨεʹΑΔฒͼସ͑ɺϢʔβʔ໊ʹΑΔݕࡧ
  26. %ZOBNP%#ͷεΩʔϚʹམͱ͠ࠐΉ

  27. %ZOBNP%#ͷεΩʔϚʹམͱ͠ࠐΉ

  28. 03.෩ͳϝιουˍద੾ͳϞδϡʔϧ෼͚ %ZOBNP%#Λҙࣝ͢Δ͜ͱ͕ݮΓɺϩδοΫ࣮૷ʹूதͰ͖Δ👍 IUUQTNFNFNFNPNPCPPUIQNJUFNT

  29. .2555PQJDઃܭ

  30. .255ͷ5PQJDͱ͸ʁ w Πϝʔδͱͯ͠͸3&45"1*Ͱ͍͏ͱ͜ΖͷΤϯυϙΠϯτͷΑ͏ͳ΋ͷ ྫʮEFWJDFEFUFDUJPO\EFWJDFJE^ʯ ɻ w "84*P5Ͱ.255ͷ5PQJDΛݩʹ-BNCEB΁ৼΓ෼͚Λߦ͏ σόΠε Ϋϥ΢υ ɻ

    w ·ͨɺ-BNCEBଆ͔Β*P5σόΠε΁.255௨৴Λߦ͏͜ͱ΋͋Δ Ϋϥ ΢υσόΠε ɻ
  31. .255ઃܭʹؔ͢ΔϗϫΠτϖʔύʔ͕͋Δ👇 IUUQTEBXTTUBUJDDPNXIJUFQBQFST %FTJHOJOH@.255@5PQJDT@GPS@"84@*P5@$PSFQEG

  32. w Ϋϥ΢υ͔ΒσόΠʹ޲͚ͯ ԿΒ͔ͷૢ࡞Λ͢Δ৔߹΍ɺ ૒ํ޲ʹίϛϡχέʔγϣϯ ͕ඞཁͳ৔߹ɻ w #SPBEDBTUύλʔϯͱݺ͹Ε ΔɺҰରଟ ҰͭͷΫϥ΢υɺ ଟ͘ͷσόΠε

    ͷίϛϡχ έʔγϣϯɻ w ྫΫϥ΢υ͔ΒԻ੠σʔλΛ σόΠε΁ૹ৴ɺ࠶ੜͤ͞Δ ઃܭ֓ཁ $PNNBOET 5FMFNFUSZ w σόΠε͔ΒΫϥ΢υ΁σʔ λΛૹ৴͢Δ৔߹ɻ w 'BO*Oύλʔϯͱݺ͹ΕΔɺ ଟରҰ ଟ͘ͷσόΠεɺҰͭ ͷΫϥ΢υ ͷίϛϡχέʔ γϣϯɻ w ྫిٿͷ৭ΛσόΠεͰઃ ఆɺΫϥ΢υଆͷγϟυ΢ʹ อ࣋
  33. 5FMFNFUSZͷྫ 5FMFNFUSZͷγϯλοΫε͸ ʮEUBQQMJDBUJPODPOUFYUUIJOHOBNFEUUZQFʯ

  34. $PNNBOETͷྫ $PNNBOETͷγϯλοΫε͸ ʮDNEBQQMJDBUJPODPOUFYUEFTUJOBUJPOJESFRUZQFʯ

  35. %ZOBNP%#τϥϯβΫγϣϯ

  36. %ZOBNP%#ͰτϥϯβΫγϣϯͷαϙʔτ

  37. Ұൠతͳ3%#ͷτϥϯβΫγϣϯͱ͸ҟͳΔ੍ݶ͕͋Δ %ZOBNP%#ͷτϥϯβΫγϣϯʹ͍ͭͯ'"2ܗࣜͰ౴͑ͯΈΔ IUUQTEFWDMBTTNFUIPEKQDMPVEBXTEZOBNPECUSBOTBDUJPOTGBR தͰ΋ ʮಉ࣌ʹૢ࡞Ͱ͖Δ*UFN͸݅·Ͱʯ ͜ͷ੍ݶ͸ҙࣝ͠ͳ͍ͱ؆୯ʹ௒աͯ͠͠·͏

  38. ؔ࿈͢ΔϨίʔυΛ࡟আ͓͖͍ͯͨ͠

  39. %ZOBNP%#Ҏ֎ͷαʔϏεͷߋ৽΋ඞཁ

  40. Ϩίʔυ͸Ώ͏ʹ݅Λ௒͑Δ ࣮ߦ࣌ؒ΋ɺ"1*ͱͯ͠ڐ༰Ͱ͖ͳ͘ ͳͬͯ͠·͏

  41. ͦ΋ͦ΋ɺ݁Ռ੔߹ੑͷߟ͑ํʹै͏ͱɺ ૄ݁߹ʹߋ৽͢Δ΂Ͱ͸ͳ͍͔ʁ

  42. "844UFQ'VODUJPOT

  43. 4UFQ'VODUJPOTͱ͸ʁ ෳ਺ͷ-BNCEBΛ૊Έ߹Θͤͯɺ ࿈ಈతʹ࣮ߦ͢Δ͜ͱ͕Ͱ͖Δɻ

  44. ࠓճͳʹ͕Α͔͔ͬͨʁ w ॲཧΛૄ݁߹ʹ෼཭Ͱ͖Δ w Ұ౓"1*ͱͯ͠ͷϨεϙϯε͸ฦͨ͋͠ͱɺ4UFQ'VODUJPOTͰ ඇಉظʹผͷॲཧ࣮ߦ͢Δ͜ͱ͕Ͱ͖Δ w ෳ਺ͷ"84αʔϏε΋ඇಉظʹॲཧͰ͖Δ w ๛෋ͳϦτϥΠઃఆ

    ΤϥʔछผʹΑΔϦτϥΠੋඇ൑ผɺ࠷େ ࢼߦճ਺ɺόοΫΦϑͳͲ  w -BNCEBಉ࢜ͷؔ܎Λࢹ֮Խ
  45. ݞ෯ͷ޿͍4UFQ'VODUJPOT͕Ͱ͖͕͋Γ·ͨ͠ʜ🎉😷

  46. ϚωʔδυͳΒͰ͸ͷ੍ݶɻ࢓༷ͷ߹ҙ͕ॏཁ IUUQTTQFBLFSEFDLDPNXBEBZVTVLFUIFDPODFQUPGTFSWFSMFTTJO BQQMJDBUJPOEFWFMPQNFOU TMJEF

  47. -BNCEBͷ؂ࢹ

  48. ྫ֎؂ࢹʹ͍ͭͯ͸%BUBEPH $MPVE8BUDI -BNCEBͷ؂ࢹ w ͻͱͭͷ-BNCEBؔ਺ IBOEMFS ୯ҐͰ؂ࢹ w "84Ϛωʔδυͷੑ্࣭ɺαʔόʔΤϥʔͱ͍͏ΑΓ͸ɺجຊ తʹΞϓϦέʔγϣϯଆͷΤϥʔͱͳΔ

  49. ͋Δͱ͖ϛεͬͯ͠·͍ɺ-BNCEBؔ਺Λແݶݺͼग़͢͠Δ Α͏ͳ࣮૷Λॻ͍ͯ͠·ͬͨɻ ࣮ࡍʹ͋ͬͨා͍࿩ʜ ໿೔Ͱԯճͷ࣮ߦ😨 ܻສԁͰऩ·͕ͬͨɺ෇ਵ͢ΔαʔϏε 93BZ $MPVE8BUDI-PHͳͲ ΋ՃΘΓɺ ͚ͬ͜͏ͳֹΛ੥ٻ͞Εͯ͠·ͬͨʜɻ

  50. w (Pͷؔ਺໊͕Θ͔Γʹ͘͘ɺ͋ΔαʔϏεΛݺͼग़͢΂͖ͱ͜ ΖͰɺ-BNCEBͷ࣮ߦΛ͢ΔΑ͏ͳॲཧΛͯ͠͠·͍ͬͯͨɻ w ։ൃ؀ڥͩͬͨͷͰɺ؂ࢹΛ͍ͯ͠ͳ͔ͬͨɻ w ։ൃ؀ڥͰ΋ -BNCEB͕ແݶʹεέʔϧͯ͠͠·͏ͷͰؾͮ ͔ͳ͍ɻ ෳ਺ͷཁҼ

    4FSWFSMFTTͳΒͰ͸ͷ؂ࢹ؍఺
  51. w ੥ٻΞϥʔτΛઃఆ͢Δ w ্ݶ͍͘ΒΛ"84ଆͰઃఆͰ͖Δ w ։ൃ؀ڥͰ΋%BUBEPH؂ࢹΛߦ͏ w ಉ࣮࣌ߦ਺ͷ੍ݶΛ͔͚Δ w ؔ਺໊Λ͍͍ײ͡ʹ͢Δ💧

    ࣮ࡍͷରॲ
  52. w -BNCEBؔ਺ͷ݁߹ςετ ։ൃதͳ͜ͱɺ%ZOBNP%#ͷσʔλΛ੔උ͢Δ ޻਺͕͔͔Δ͜ͱ͔Βɺϲ݄ͳͲେ͖ͳ୯ҐͰ͠ ͔݁߹ςετ͕Ͱ͖͍ͯͳ͍ Ͳ͏ʹ͔͍ͨ͜͠ͱ

  53. ·ͱΊ w 4FSWFSMFTTΞϓϦέʔγϣϯͷ؅ཧ w "844".ͱࣗಈੜ੒ w %ZOBNP%#ςʔϒϧઃܭ w ϕετϓϥΫςΟεʹै͏ʴ%ZOBNP%#Λҙࣝ͠ͳ͍࢓૊Έͮ͘Γ w

    %ZOBNP%#τϥϯβΫγϣϯ w 4UFQ'VODUJPOTͰ͕Μ͹Δ w .2555PQJDઃܭ w $PNNBOET5FMFNFUSZ w -BNCEBͷ؂ࢹ w Ϋϥ΢υഁ࢈ʹ஫ҙ