Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
実践的データ基盤への処方箋_2-9_2-12
Search
Tomoya Koike
February 03, 2022
Programming
0
160
実践的データ基盤への処方箋_2-9_2-12
Tomoya Koike
February 03, 2022
Tweet
Share
More Decks by Tomoya Koike
See All by Tomoya Koike
CDLE youth LT会 #1
koikeya
0
88
Other Decks in Programming
See All in Programming
見えないメモリを観測する: PHP 8.4 `pg_result_memory_size()` とSQL結果のメモリ管理
kentaroutakeda
0
670
Zoneless Testing
rainerhahnekamp
0
120
AWSのLambdaで PHPを動かす選択肢
rinchoku
2
150
PHPとAPI Platformで作る本格的なWeb APIアプリケーション(入門編) / phpcon 2024 Intro to API Platform
ttskch
0
300
php-conference-japan-2024
tasuku43
0
350
Cloudflare MCP ServerでClaude Desktop からWeb APIを構築
kutakutat
1
560
テストコード文化を0から作り、変化し続けた組織
kazatohiei
2
1.5k
命名をリントする
chiroruxx
1
440
Jakarta EE meets AI
ivargrimstad
0
270
KMP와 kotlinx.rpc로 서버와 클라이언트 동기화
kwakeuijin
0
180
KubeCon + CloudNativeCon NA 2024 Overviewat Kubernetes Meetup Tokyo #68 / amsy810_k8sjp68
masayaaoyama
0
260
rails statsで大解剖 🔍 “B/43流” のRailsの育て方を歴史とともに振り返ります
shoheimitani
2
950
Featured
See All Featured
Become a Pro
speakerdeck
PRO
26
5k
The World Runs on Bad Software
bkeepers
PRO
66
11k
Statistics for Hackers
jakevdp
796
220k
Building Applications with DynamoDB
mza
91
6.1k
Bootstrapping a Software Product
garrettdimon
PRO
305
110k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
28
2.1k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
44
6.9k
Raft: Consensus for Rubyists
vanstee
137
6.7k
Automating Front-end Workflow
addyosmani
1366
200k
Designing for humans not robots
tammielis
250
25k
Art, The Web, and Tiny UX
lynnandtonic
298
20k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
33
2k
Transcript
࣮ફత デ ʔλج൫ͷॲํᝦ ྠಡձ 2-9 ~ 2-12 খஐ࠸
2−9 ϩάऩूΤʔδΣϯτͷΩϟύγςΟʹҙ
ϩάͱ 3 Α͘ੳ͞ΕΔϩά 1. WebαʔόͷΞΫηεϩά 2. ΞϓϦέʔγϣϯͷϩά WebαʔόͷΞΫηεϩάͷྫ • ΞΫηεͨ࣌ؒ͠ɺURL
• ΞΫηεݩͷIPΞυϨε • ΞΫηεʹ༻͍ͨใ • Web App͕ઃఆͨ͠ɺϢʔβࣝผใ
ϩάϩάऩूΤʔδΣϯτͰऩू͢Δ 4 ϩάऩूΤʔδΣϯτ • όοϑΝʹΑΓϩάऩूϚωʔδϟͷෛՙΛҰఆʹͰ͖Δ • όοϑΝ͕ᷓΕͳ͍Α͏ʹαΠζΛ֬อ͢Δ͜ͱʹҙ͕ඞཁ
ϩάऩू͕Ͱ͖Δ 5 ໊ ఏڙํ๏ ఏڙɾαϙʔτ ͍ͯ͠Δձࣾ fluentd, fluent-bit OSS Treasure
Data Logstash OSS Elastic CloudWatch Cloud AWS Cloud Logging Agent Cloud GCP
2−10 σʔλͷऩूқ͕ߴ͍ͨΊ Ͱ͖Δ͚ͩΛར༻͠ແཧͳΒࣗ࡞͢Δ
σʔλେྔ͕ͩ༗༻ 7 දతͳσʔλ ϒϥβΠϕϯτ εϚϗΞϓϦΠϕϯτ IoTσόΠεσʔλ ը໘ͷεΫϩʔϧϚεͷيɺϢʔβͷϒϥβ্Ͱͷૢ࡞σʔλ εϚϗΞϓϦ্ͰͷϢʔβͷૢ࡞σʔλ ंࡌηϯαʔͷσʔλɺڥηϯαɺΤΞϥϒϧσόΠε
ϒϥβΠϕϯτεϚϗΞϓϦΠϕϯτσʔλऩूΛར༻ 8 ཉ͍͠σʔλΛऩूͰ͖Δ͕ͳ͍͔Λ୳͢ Ϣʔβͷ্ͷߦಈੳπʔϧଟ͘ଘࡏ͢Δ ϒϥβΠϕϯτ εϚϗΞϓϦΠϕϯτ Adobe AnalyticsGoogle Analytics
Google Analytics For Firebase
ࣗ࡞͢Δ߹ࢄϝοηʔδΩϡʔΛ͏ 9 ϩάऩूπʔϧΛࣗ࡞͢Δ໘ • IoTσόΠεͷσʔλͰɺΫϥυαʔϏεʹ͍͍ͷ͕ͳ͍ͱ͖ • ΞΫηεղੳπʔϧͰेͳσʔλ͕ಘΒΕͳ͍߹ • ϩά༰ΛϦΞϧλΠϜʹ׆༻͢Δඞཁ͕͋Δͱ͖I ࢄϝοηʔδΩϡʔʹϩάΛૹ৴͢Δ
ࣗ࡞͢Δ߹ࢄϝοηʔδΩϡʔΛ͏ 10 ࢄϝοηʔδΩϡʔ ΩϡʔͱɺઌೖΕઌग़͠ͷσʔλߏͷ͜ͱɻ ΩϡʔΠϯά͢Δϓϩσϡʔαͱɺpop͢ΔίϯγϡʔϚͷ2ͭͷׂ͕͋Δɻ
ࢄϝοηʔδΩϡʔͷҙ͖͢ಛͱӡ༻ͷίπ 11 ࢄϝοηʔδΩϡʔͷҙ͖͢ಛ 1. ॱংੑอূͷ༗ແ…ॱং͕ඞཁͳ߹λΠϜελϯϓΛೖΕͯฒͼସ͑Δ͕ඞཁ 2. ϝοηʔδͷॏෳ༗ແ…ॲཧΛႈʹ͢Δ͔ɺॲཧ༗ແͷஅϩδοΫΛೖΕΔ 3. ՄࢹੑλΠϜΞτ…ॲཧ࣌ؒΑΓ͍ͱɺॲཧ͕2ճҎ্Δ ӡ༻ͷίπ
• ίϯγϡʔϚ͕ॲཧʹࣦഊ͠ଓ͚ͨσουϨλʔΛઐ༻ͷΩϡʔʹೖΕΔ • ϓϩσϡʔαʔ͕ੜྔΛ੍͢ΔόοΫϓϨογϟʔͱ͍͏ΈΛೖΕΔ
۩ମతͳγεςϜͷ࡞Γํ 12 ࢄϝοηʔδΩϡʔ
2−11 ETLΛબͿϙΠϯτར༻͢Δ ίωΫλͷػೳੑͱσόοάͷ͢͠͞
ETLͱ 14 ఏڙܗଶͷҧ͍ ETL…Extract Transform LoadͷུͰɺσʔλͷநग़ɺՃɺϩʔυΛҙຯ͢Δɻ ෳࡶͳՃ͕Ͱ͖Δ͔Ͳ͏͔ ҟͳΔσʔλιʔε͔ΒͷσʔλΛՃɺ݁߹ͯ͠ϩʔυ͢Δɻ Apache Nifi,
DataSpider, Glue, Cloud Data Fusion OSSɺ༗ঈɺΫϥυͷ3छྨɻ OSS…embulkfluentd, Apache Sqoop, ༗ঈͱͯ͠DataSpider, ASTERIAͳͲɻ ΫϥυͰAWSͷGlueGCPͷCloud Data Fusion, ྆αʔϏεͷDMS, embulkͷϚωʔδυαʔϏεͰ͋ΔtroccoͳͲɻ ※DMS…Database Migration Service
͏ίωΫλͷػೳΛॏࢹ͢Δ 15 MySQLίωΫλͰ͋ΕɺWHERE۟ࠩͷΈऩू͕Ͱ͖Δ͔ɻ ϏοάσʔλͰ͋ΕɺࢄॲཧͰ͖Δ͔ʹҙ͢Δɻ
ιʔείʔυϨϕϧͰσόοά͍͢͠ͷΛར༻͢Δ 16 όά͕ى͖ͨͱ͖ɺσʔλιʔεɾ֨ೲઌɾऩू͠Α͏ͱ͢ΔσʔλͷΈ߹ ΘͤʹΑͬͯ࠶ݱྫ͕ͳ͍͜ͱɻ ίωΫλͷιʔείʔυΛݟʹߦ͚Δͷ͕େࣄɻ ETLͷαϙʔτʹௐࠪͯ͠Β͏ͱ͖ɺσʔλج൫ʹೖͬͯΒ͏Α͏४උɻ σʔλʹґଘͯ͠ى͖Δόά ఆ͍ͯ͠ͳ͍จࣈίʔυ੍ޚจࣈɺվߦίʔυ nullΛظ͢Δͱ͜Ζʹۭจࣈྻ
ΤϯδχΞ͕͍ͳ͚ΕϓϩάϥϛϯάϨεͷETLબࢶͷ1ͭ 17 ઐ༻ͷը໘্Ͱσʔλιʔε֨ ೲઌͷΞΠίϯΛͭͳ͛ͯETLॲ ཧΛఆٛɺσϓϩΠͰ͖Δɻ Apache Nifi, Talend, DataSpider, ASTERIA,
Glue, Cloud Data Fusion ͳͲɻ
2−12 σʔλϨΠΫͰऩूͨ͠σʔλ Λͳ͘͞ͳ͍Α͏ʹ͢Δ
ऩूͨ͠σʔλΛݪଇͦͷ··ੵ͢Δ 19 σʔλϨΠΫʹऩूͨ͠σʔλΛՃͤͣʹ֨ೲ͢Δ σʔλϨΠΫʹԽͰ͖༰ྔ͕֦ுͰ͖ΔΛબͿ ऩूͨ͠σʔλΛͳ͘͞ͳ͍ͨΊʹԽ͢Δ͜ͱɺ σʔλ༰ྔΛ૿ͤΔΑ͏ʹ͓ͯ͘͜͠ͱ͕ॏཁɻ ϑΝΠϧJSONܗࣜɺςʔϒϧߏͳͲΛͦͷ··อଘɻ Ճʹࣦഊͯ͠σʔλଛࣦ͢Δ͜ͱΛ͙ͨΊɻ ػີใݸਓใಗ໊ԽΛߦͬͯੵ͢Δɻ
ϑΝΠϧΦϒδΣΫτετϨʔδʹੵ͢Δ 20 ෳͷσʔληϯλʔͰෳσόΠεʹ Խͯ͠อଘ͢Δ͜ͱͰɺ ΠϨϒϯφΠϯͷݎ࿚ੑͱ 99.99%ͷՄ༻ੑΛ࣮ݱ͍ͯ͠Δɻ σʔλΛʮΦϒδΣΫτʯͱ͍͏୯ҐͰѻ͏هԱஔɻ ΫϥυαʔϏεͱͯ͠S3Cloud StorageͳͲ͕͋Δɻ ΦϒδΣΫτετϨʔδ
ΦϯϓϨͷ߹ࢄετϨʔδΛར༻ɻ OSSͱͯ͠HDFSͳͲɻ
CSVJSONσʔλσʔλϕʔεʹೖΕͯOK 21 CSVJSONσʔλΛDWH༻ੳDBʹೖΕΔ ੳ༻DBͷதͰɺੜͷσʔλ Λ֨ೲ͢ΔσʔλϨΠΫͱ Ճ͞ΕͨσʔλΛ࣋ͭDWH ʹ͚Δ JSONʹ͍ͭͯɺจࣈྻܕ·ͨJSONܕͱͯ֨͠ೲ͢Δ
σʔλ͕ΦϯϓϨϛεʹ͋ͬͯσʔλϨΠΫΫϥυʹ͢Δ 22 3ͭͷཧ༝ ैྔ՝ۚͰར༻Ͱ͖ΔͨΊ ٱੑ͕ߴ͍ͨΊ ӡ༻ਓ݅අ͕͍҆ ج൫ߏங࣌ʹσʔλྔΛਖ਼֬ʹݟੵΔͷࠔͳͨΊ AWS S3ͷٱੑΠϨϒϯφΠϯͰ͋ΓɺΦϯϓϨͰఢΘͳ͍ αʔόͷߏΛؾʹ͠ͳͯ͘Α͍ͷͰɺඞཁͳٕज़ྗ͕Լ͕Δ
σϝϦοτͱͯ͠ɺࡉ҆͘ఆ͠ͳ͍ωοτճઢ͔ɺߴ͍ઐ༻ઢ͔Λ༻͍Δඞཁ͕͋Δ