Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Yahoo! JAPANアプリとLayered Architecture
Search
Takuya Shigemoto
March 12, 2018
Technology
2.3k
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Yahoo! JAPANアプリとLayered Architecture
2018.03.12(Mon)にBonfire Android #3で発表した資料です。
Takuya Shigemoto
March 12, 2018
Transcript
32 slides
Yahoo! JAPANΞϓϦͱ Layered Architecture Ϡϑʔגࣜձࣾ ॏݩ
About me • ॏݩ ʢtwitter: @shgmn9ʣ • Android / iOS
• Ϡϑʔגࣜձࣾʢ2017.07ʙʣ • Android൛ Yahoo! JAPANΞϓϦ • Χϝϥͱੜ͖͕͖ • ञ
ΞδΣϯμ • Yahoo! JAPANΞϓϦ๊͕͍͑ͯͨ • Layered Architectureಋೖ • Layered ArchitectureಋೖͷՌ
• ઃܭΛҡ࣋͢ΔऔΓΈ • ͜Ε͔Β • ·ͱΊ
Yahoo! JAPANΞϓϦ͕ ๊͍͑ͯͨ ࣸਅɿΞϑϩ
ࣸਅɿΞϑϩ • େਓͷ։ൃͰɺෳҊ͕݅ฒߦͯ͠Δ • ໌֬ͳઃܭํ͕ແ͍ • Ϣχοτςετ͕ॻ͖ͮΒ͍
ઃܭͷબ ࣸਅɿΞϑϩ
Model View Whateverʁ ࣸਅɿΞϑϩ • Model View Whatever • MVP…ModelͱViewͱPresenter
• MVVM…ModelͱViewͱViewModel • Presentation Domain SeparationʢPDSʣ • Presentation…ೖྗΛड͚औΔɺݟͨΛ࡞Δ • Domain…ͦΕҎ֎
Presentationʹ͍ͭͯ ࣸਅɿΞϑϩ • Presentationͷ࣮ݱ • MVP…ViewͱPresenter • MVVM…ViewͱViewModel
Domainʹ͍ͭͯ ࣸਅɿΞϑϩ • Domainʁ • MVPMVVMͷMʢModelʣͷ͜ͱ • Domainͷઃܭʹ͍ͭͯMVWͰ৮Ε͍ͯͳ͍
Layered Architectureಋೖ ࣸਅɿΞϑϩ
goo.gl/GTAfLv
Application Presentation Domain Infrastructure ViewͱWhatever Model
Application Presentation Domain Infrastructure Ϣʔβೖྗɺදࣔ Presentation͕ୟ͘૭ޱ υϝΠϯΞΫηε͠ϢʔεέʔεΛ࣮ݱ ϏδωεϩδοΫ ֎෦ͷΞΫηεʢωοτϫʔΫɾDBɾetc…ʣ
ಋೖํ๏ • ϨΠϠʔׂΛ࣮ࡍʹίʔυʹద༻͢ΔͨΊʹ • ઃܭنҧΛػցతʹ͘Έ͕ඞཁ • ֤ϨΠϠʔผϞδϡʔϧʹׂ ࣸਅɿΞϑϩ
Application Presentation Domain Infrastructure compile project(‘:Application’) compile project(‘:Domain’) compile project(‘:Infrastructure’)
Application Presentation Domain Infrastructure Observable Observable Observable
αʔϏεͷάϩʔε • ػೳՃࢭ·Βͳ͍ • ಉҰػೳͷϦϑΝΫλϦϯάͱػೳՃ͕ಉ࣌ʹΒͳ ͍Α͏ʹεέδϡʔϧΛҾ͍ͨ ࣸਅɿΞϑϩ
࣭ • େنͳϦϑΝΫλϦϯάͷલޙͰͷ࣭୲อ • ApplicationϨΠϠʔҎԼϢχοτςετʢC0ʣΛٛ ͚ͨ • Coverage 80%Ҏ্ ࣸਅɿΞϑϩ
ఘΊͨ͜ͱ • DIಋೖ • Dagger2ֶशίετΛߟ͑ͯಋೖΛఘΊͨ ࣸਅɿΞϑϩ
Layered Architecture ಋೖͷՌ ࣸਅɿΞϑϩ
ಘͨͷ • ίʔυ͕͖Ε͍ʹͳͬͨ • ػೳՃͷࡍʹΉ͜ͱ͕ݮͬͨ • ϝϯόͷٕज़Ϩϕϧ͕ͨ͠ • ৽نʹδϣΠϯ͘͢͠ͳͬͨ ࣸਅɿΞϑϩ
Layered ArchitectureΛ ҡ࣋͢ΔऔΓΈ ࣸਅɿΞϑϩ
• ίϛολʔ੍ • ༷ڞ༗ձ • ઃܭϨϏϡʔձ ࣸਅɿΞϑϩ
ίϛολʔ੍ • ֓ཁ • ઃܭɾ࣮ํΛཧղͨ͠ϝϯόʔʢίϛολʔʣʹϓϧϦΫΤε τͷϨϏϡʔͷΛෛͬͯΒ͏ • ϓϧϦΫΤετͷϚʔδʹɺ࠷1ਓͷίϛολʔͷঝೝ͕ඞཁ • త
• େنϦϑΝΫλϦϯάޙͷίʔυΛܧଓతʹ͖Ε͍ͳঢ়ଶʹอͭ • ݱࡏʢ2018.03ʣ • ։ൃϝϯό21ਓʹର͠ίϛολʔ5ਓ ࣸਅɿΞϑϩ
༷ڞ༗ձ • ֓ཁ • Ҋ༷݅Λ؆୯ʹυΩϡϝϯτʹ·ͱΊɺΤϯδχΞ ؒͰڞ༗͢Δձ • త • ଐਓԽΛղফ͢Δ
• ༷ͷٕज़తͳݒ೦Λઃܭલʹચ͍ग़͢ • ଞҊ݅ͱͷฒߦ։ൃͷ࣮ݱՄೳੑΛݕ౼͢Δ ࣸਅɿΞϑϩ
ࣸਅɿΞϑϩ ઃܭϨϏϡʔձ • ֓ཁ • ༷ڞ༗ձͰγΣΞ༷ͨ͠ʹؔ͢ΔઃܭΛυΩϡϝ ϯτʹ·ͱΊɺΤϯδχΞؒ • త •
ઃܭํΛἧ͑ɺΞϓϦͷઃܭɾ࣭Λҡ࣋͢Δ
͜Ε͔Β ࣸਅɿΞϑϩ
͍͖͍ͬͯͨऔΓΈ • UIͷςετ • DI • AACʢLifecycleɺViewModelɺLiveDataʣ • ϏϧυͷߴԽ •
ػೳ͝ͱͷϚϧνϞδϡʔϧԽ ࣸਅɿΞϑϩ
·ͱΊ
·ͱΊ • ղܾ͍ͨ͠Λ͖ͪΜͱݟఆΊͯಋೖ͢ΔઃܭΛܾΊ Δ͜ͱ • ઃܭͷಋೖʹ͋ͨͬͯɺແཧ͠ͳ͍͜ͱ • ϏδωεଆͷཧղΛ͖ͪΜͱಘΔ͜ͱ • ઃܭΛҡ࣋͢ΔͨΊͷࢪࡦΛ͖ͪΜͱߦ͏͜ͱ
Yahoo! JAPANͰ ༷ʑͳྖҬͰΤϯδχΞΛืू͍ͯ͠·͢ʂ https://about.yahoo.co.jp/hr/ ࣸਅɿΞϑϩ
Thank you!
More Decks by Takuya Shigemoto
See All by Takuya Shigemoto
Google I/O Extended Tokyo 2018レポート
shgmn
1
790
Other Decks in Technology
See All in Technology
Del vibe coding a un Desarrollo (agéntico) fiable
jcabot
0
220
Amazon EFS のマルウェアスキャンをClamAV で自前実装したら苦労した話
mtmtfactory01
0
120
正しくWeb サイトを守るためのコンテンツセキュリティーポリシー
hinalin
0
160
20261119_AgentCore
takuyay0ne
2
300
PHPで家庭用ゲーム機の専用コントローラーをMIDIデバイスとして扱ってみる
wind111
0
200
OCI Artifact による自動運転タクシーに向けた OTA 基盤の構築
biwashi
1
300
Kiro Enterprise Management: 管理者が 1 か所で決め、全員の Kiro に届ける
inariku
PRO
0
110
Test Impact Analysis を武器に立ち向かう、AI 時代のテスト増加に対するヌーラボのアプローチ / getting-started-datadog-test-impact-analysis
k6s4i53rx
3
880
メルカリの小規模チーム「Pod」で、 エンジニアがデータアナリストなしで、 AIを使ってデータ分析の自走を目指す取り組み
jackojacko_
1
360
目を覚ませ!僕らの認証情報が何者かに侵略されてるぞ
tkito
2
490
技術書典で本を売る流れ
yoshimura_datam
0
160
新規事業開発でのAWS活用成功談&失敗談! 〜新規事業開発を専門に行うRelicならではのAWS活用〜
amixedcolor
1
150
Featured
See All Featured
YesSQL, Process and Tooling at Scale
rocio
174
15k
Keith and Marios Guide to Fast Websites
keithpitt
413
23k
Test your architecture with Archunit
thirion
2
2.5k
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
630
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.6k
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
3
1.5k
Gemini Prompt Engineering: Practical Techniques for Tangible AI Outcomes
mfonobong
2
650
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.5k
コードの90%をAIが書く世界で何が待っているのか / What awaits us in a world where 90% of the code is written by AI
rkaga
63
48k
The SEO Collaboration Effect
kristinabergwall1
1
630
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
Optimizing for Happiness
mojombo
378
72k