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

ウェブ地図「地理院地図」with Fastly

Shinya Omori
November 25, 2020

ウェブ地図「地理院地図」with Fastly

Yamagoya Traverse 2020 | Fastly
DAY 1 2020.11.25
https://www.fastly.jp/yamagoya2020

Shinya Omori

November 25, 2020
Tweet

More Decks by Shinya Omori

Other Decks in Technology

Transcript

  1. 2 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE େ৿ ৴࠸ !TIJOQZ גࣜձࣾΞτϛςοΫʢॴଐΦϑΟεɿळ༿ݪ6%9ʣ Ϋϥ΢υαʔϏεࣄۀͰ͋Δ Ϋϥ΢σΟ

    Λ୲౰ ෱ౡݝձ௡एদࢢ ࡏॅʢϑϧɾϦϞʔτʣ ΠϯϑϥΤϯδχΞ݉ΤόϯδΣϦετ ࠷ۙ͸0$*ʢ0SBDMF $MPVE *OGSBTUSVDUVSFʣΛओͱͯ͠୲౰ ˞ଞʹɺ"84 ɺ "[VSFҊ݅ɺكʹΦϯϓϨ΋ɻɻɻ ʹग़ձͬͯ೥Ґ ˗*5ίϛϡχςΟ
  2. 6 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE ͓٬༷ɿࠃ౔஍ཧӃ ༷ Ҋ ݅ɿ஍ཧӃ஍ਤαʔόӡ༻ۀ຿ ʮ஍ཧӃ஍ਤʯͱ͸ʁ ࠃ౔஍ཧӃ͕੔උͨ͠஍ܗਤɺࣸਅɺ

    ඪߴɺ஍ܗ෼ྨɺࡂ֐৘ใͳͲɺ ೔ຊͷࠃ౔ͷ༷ࢠΛൃ৴͢Δ΢Σϒ஍ਤ IUUQTNBQTHTJHPKQ !HTJ@DZCFSKBQBO !HTJDZCFSKBQBO ˞஍ཧӃ஍ਤͷιʔεϑΝΠϧΛ044ͱͯ͠ެ։
  3. 7 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE ʲۀ຿಺༰ʳ • ஍ཧӃ஍ਤΛՔಇͤ͞ΔΠϯϑϥج൫Λఏڙˍӡ༻ ʲಛ௃ʳ • $%/@഑৴ྔ

    ɿ໿5#݄ • $%/@ϦΫΤετ਺ ɿ໿ ԯ3FR݄ • ΦϦδϯ@ετϨʔδ༰ྔɿ໿ 5# ˞஍ਤσʔλ֨ೲ • ஍਒ɾ୆෩ͳͲͷࣗવࡂ֐ൃੜ࣌౳ʹεύΠΫΞΫηε͕ ൃੜ͢Δ৔߹͕͋Δ
  4. 9 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE • ࡢ೥౓·Ͱ͸"84Ͱӡ༻͍ͯͨ͠ • ฐࣾ͸Ϋϥ΢υج൫ͱͯ͠0$*ʢ0SBDMF $MPVE *OGSBTUSVDUVSFʣΛఏҊ

    ʲ 0$*ಛ௃ʳ  ʮωοτϫʔΫ௨৴අʯ͕҆Ձ Ø Ξ΢τό΢ϯυ௨৴͸5#݄·Ͱແྉ Ø Πϯό΢ϯυ௨৴͸શͯແྉ Ø Ϧʔδϣϯ಺ͷαʔϏεαʔόؒͷ௨৴ྉۚແྉ Ø ઐ༻ઢͷ௨৴ྉۚແྉ  ʮΠϯελϯεඅ༻ʯ͕҆Ձ Ø ଞࣾΫϥ΢υͱൺ΂Δͱ҆Ձʹઃఆ͞Ε͍ͯΔ Ø ࠷৽".% $16Λ҆Ձʹར༻Մೳ Ø $16ͱϝϞϦΛ̍୯ҐͰ૿ݮͰ͖ΔϞσϧ΋ఏڙ Ø ݻఆάϩʔόϧ*1͸ར༻͍ͯ͠ͳ͘ͱ΋ແྉ ͔͠͠ɺ0$*Ͱ͸$%/αʔϏεΛఏڙ͍ͯ͠ͳ͍ɻɻɻ
  5. 10 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE 0$*ʹ$%/͕ͳ͍ ʢଈܾʣ • 0$*ΛऔΓѻ͏Α͏ʹͳ͔ͬͯΒɺ'BTUMZΛௐࠪݕূ͍ͯͨ͠ • ΤοδαʔϏεͱ༷ͯ͠ʑͳػೳΛఏڙˍࠃ಺ࣄྫ΋૿͖͍͑ͯͯΔ

    ಋೖલ'BTUMZΠϝʔδ ɾΩϟογϡύʔδ͕ߴ଎ ɾϩάΛϦΞϧλΠϜग़ྗ ɾϩʔυόϥϯγϯάͰ͖ΔʢҠߦͰ׆༻ʁʣ ɾΧελϜ7$-Ͱػೳ֦ுՄೳ ɾதͷํʑΈΜͳڧͦ͏ʂʂ ɾ$%/഑৴ྔˍϦΫΤετ਺͕ଟ͍ͷͰσΟεΧ΢ϯτͰ͖ͦ͏ʂʂ
  6. 12 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE • $%/ʹ$MPVE'SPOUͰఏڙ • ੩తίϯςϯπσʔλʢ4ʣɿ໿5# • ੩తίϯςϯπߋ৽͸ຖि਺ճʢߴස౓ʣ

    ʹ Ωϟογϡύʔδස౓΋ଟ͍ • ஍ਤݕࡧػೳ౳ͷ"1*αʔόఏڙʢ&$ʣ • େྔͷϩάղੳʢ"NB[PN &.3ʣ "1*47 ຊ൪ "84 $MPVE $%/ "NB[PO$MPVE'SPOU %PDLFS ίϯςφ "1*47 ςετ Πϯλʔωοτ %PDLFS ίϯςφ ίϯςϯπΛ Ξοϓϩʔυ %PDLFSΠϝʔδΛ σϓϩΠ 71$ ΦϑΟε౳ &.3 &$ &$ 4 "84ߏ੒࣌ʢࡢ೥౓ʣ
  7. 13 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE "1*47 ຊ൪ 0$* 7$/ $PNQVUF $PNQVUF

    %PDLFS ίϯςφ "1*47 ςετ Πϯλʔωοτ 0CKFDU 4UPSBHF %PDLFS ίϯςφ ΦϑΟε౳ %PDLFSΠϝʔδΛ σϓϩΠ ίϯςϯπΛ Ξοϓϩʔυ • $%/ʢ$MPVE'SPOUʣˠ 'BTUMZ • 4 ˠ 0CKFDU4UPSBHF • &$ ˠ $PNQVUF • ϩάղੳʢ&.3ʣ ˠ'BTUMZ͔Βϩάग़ྗ࣌఺ͰΧελϚΠζ ˞ϦϞʔτϩάετϦʔϛϯά ˠղੳʢूܭʣɿγΣϧ 'BTUMZʴ0$*ߏ੒ʢݱࡏʣ
  8. 15 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE 3FXSJUF • 0$* 0CKFDU 4UPSBHFͷ֎෦ެ։༻63-Λ'BTUMZͰ3FXSJUF ˞4ͱҧͬͯ·ͩϗεςΟϯάαʔϏεػೳ͕ऑ͍

    Ø 0CKFDU 4UPSBHF͕ൃߦ͢Δ63- ྫɿIUUQTPCKFDUTUPSBHF DPN ུ UFTUQOH Ø 'BTUMZͰ3FXSJUF ྫɿIUUQTNBQTHTJHPKQUFTUQOH
  9. 16 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE Ωϟογϡઃఆ • ੩తίϯςϯπʢ஍ਤλΠϧσʔλʣ͸΄΅Ωϟογϡ • ಋೖ౰ॳɿΤϥʔදࣔը໘ΛΧελϜද͍ࣔͯͨ͠ʢ 4ZOUIFUJDϨεϙϯεʣ

    Ø Τϥʔදࣔը໘ΛΧελϜදࣔ͢ΔͱΩϟογϡ͞Εͳ͍࢓༷ Ø Τϥʔ͸શͯΦϦδϯʢ0CKFDU 4UPSBHFʣʹΞΫηε Ø ΦϦδϯ΁ͷτϥϑΟοΫྔɺΞΫηε਺ɺ༨ܭͳෛՙͱίετ͕ൃੜ • Τϥʔ΋Ωϟογϡ͢ΔΑ͏ʹઃఆௐ੔ Ø ΦϦδϯ΁ͷτϥϑΟοΫྔɺΞΫηε਺͕ݮগʂ Ø ίετ࡟ݮ ໿ׂ͸'BTUMZʢΩϟογϡʣͰఏڙͰ͖͍ͯΔ
  10. 17 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE Ωϟογϡύʔδ • ϫΠϧυΧʔυɾΩϟογϡύʔδ Ø 4VSSPHBUF,FZTΛ࢖༻ͨ͠ΩϟογϡύʔδͰ࣮ݱ •

    ஍ਤσʔλΛ6QMPBE͢Δ5JMF6QMPBE.BOBHFSʢ56.ʣͰͷࣗಈύʔδ Ø 1VSHF "1*࿈ܞͰ56.ʹ࣮૷ ˞1VSHF "1*ͰԠ༻͕Մೳ 56. 0CKFDU 4UPSBHF ̍ɽίϯςϯπ6QMPBE ̎ɽ6QMPBEޙɺ֘౰ՕॴΛΩϟογϡύʔδ
  11. 18 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE ϦϞʔτϩάετϦʔϛϯάઃఆ • 'BTUMZϩάΛϦΞϧλΠϜͰՕॴʢෳ਺ΤϯυϙΠϯτʣʹग़ྗ • ߲໨ΛΧελϚΠζ͓͠٬༷ͷཁ๬ʹରԠ 0CKFDU4UPSBHF

    0CKFDU4UPSBHF $PNQVUF ̍ɽ"NB[PO 4 -PHHJOH &OEQPJOU ͓٬༷ࢦఆϑΥʔϚοτͰͷϩάग़ྗ ̎ɽ"NB[PO 4 -PHHJOH &OEQPJOU ฐࣾϩάղੳ༻ϑΥʔϚοτͰͷϩάग़ྗ ̏ɽ4'51 -PHHJOH &OEQPJOU "NB[PO 4 -PHHJOH &OEQPJOUো֐౳ʹΑΔϩάܽଛରࡦ ʢ৑௕Խʣ
  12. 20 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE ࠓޙͷల๬ʢҊʣ • 'BTUMZͰϩʔυόϥϯγϯάͯ͠ࡂ֐ରࡦͰ͖ͳ͍͔ʁ 0$* Πϯλʔωοτ ΦϯϓϨ

    ଞࣾΫϥ΢υ 0$* ౦ژϦʔδϣϯ େࡕϦʔδϣϯ %$౳ "84ɺ"[VSFɺ($1౳ PS PS %3؀ڥ 参考:https://docs.fastly.com/en/guides/load-balancing-configuration
  13. 23 $PQZSJHIU˜ "UPNJUFDI *OD"MMSJHIUTSFTFSWFE ʮ'BTUMZΛબ୒ͯ͠ྑ͔ͬͨʂʂʯ • Ωϟογϡύʔδ͕ߴ଎ Ø 4VSSPHBUF ,FZΛར༻ͨ͠ύʔδͰԠ༻

    • ϩάΛϦΞϧλΠϜʹग़ྗ Ø ෳ਺ΤϯυϙΠϯτग़ྗˍΧελϚΠζ͕ศར • ϩʔυόϥϯγϯάͰ͖Δ Ø #$1%3ͱͯ͠෯͕޿͕Δ • ΧελϜ7$-Ͱػೳ֦ுՄೳ Ø 0CKFDU 4UPSBHFͷ଍Γͳ͍ػೳΛΧόʔ • தͷਓୡΈΜͳڧͦ͏ʂʂ Ø αϙʔτͷํʑ͔Βͯ͠ڧ͍ʂʂʢαϙʔτܖ໿Φεεϝʣ Ø εύΠΫΞΫηε͕͋ͬͨͱ͖΋ؾʹ͔͚ͯ͘Εͨɻ • σΟεΧ΢ϯτʜ Ø Ҋ݅֫ಘʂ ίεύ࠷ߴʂʂ