Upgrade to PRO for Only $50/Year—Limited-Time Offer! 🔥
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Mercari iOSにおける きらやばArchitectureとAutomation
Search
kagemiku
November 22, 2019
Technology
0
1.6k
Mercari iOSにおける きらやばArchitectureとAutomation
kagemiku
November 22, 2019
Tweet
Share
More Decks by kagemiku
See All by kagemiku
WWDC20 Recap of SwiftUI & Combine
kagemiku
0
4.8k
WWDC19 Recap of ML
kagemiku
0
640
Other Decks in Technology
See All in Technology
pmconf 2025 大阪「生成AI時代に未来を切り開くためのプロダクト戦略:圧倒的生産性を実現するためのプロダクトサイクロン」 / The Product Cyclone for Outstanding Productivity
yamamuteki
3
3k
機械学習を「社会実装」するということ 2025年冬版 / Social Implementation of Machine Learning November 2025 Version
moepy_stats
4
1.1k
原理から解き明かす AIと人間の成長 - Progate BAR
teba_eleven
2
190
Design System Documentation Tooling 2025
takanorip
0
520
Eight Engineering Unit 紹介資料
sansan33
PRO
0
5.6k
【保存版】「ガチャ」からの脱却:Gemini × Veoで作る、意図を反映するAI動画制作ワークフロー
nekoailab
0
120
研究開発部メンバーの働き⽅ / Sansan R&D Profile
sansan33
PRO
3
21k
ブラウザ拡張のセキュリティの話 / Browser Extension Security
flatt_security
0
220
[続・営業向け 誰でも話せるOCI セールストーク] AWSよりOCIの優位性が分からない編(2025年11月21日開催)
oracle4engineer
PRO
1
160
TypeScript 6.0で非推奨化されるオプションたち
uhyo
15
5.7k
Claude Code はじめてガイド -1時間で学べるAI駆動開発の基本と実践-
oikon48
22
13k
Data Hubグループ 紹介資料
sansan33
PRO
0
2.3k
Featured
See All Featured
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
11
950
Context Engineering - Making Every Token Count
addyosmani
9
440
Speed Design
sergeychernyshev
33
1.3k
Statistics for Hackers
jakevdp
799
230k
Stop Working from a Prison Cell
hatefulcrawdad
273
21k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
10
690
Product Roadmaps are Hard
iamctodd
PRO
55
12k
Large-scale JavaScript Application Architecture
addyosmani
514
110k
Agile that works and the tools we love
rasmusluckow
331
21k
Git: the NoSQL Database
bkeepers
PRO
432
66k
The Power of CSS Pseudo Elements
geoffreycrofte
80
6.1k
Side Projects
sachag
455
43k
Transcript
1 Mercari iOSにおける きらやばArchitectureとAutomation Akira Fukunaga (@kagemiku) iOS Engineer 2019/11/25
2 Today’s Outlines 01 • 自己紹介 02 03 • MercariにおけるiOS
Engineer • きらやばArchitectureとAutomation
3 01 自己紹介
4 Akira Fukunaga (@kagemiku) Software Engineer (iOS) Tech Lead at
NewBiz & Category
5 人生 学校 Mercari 東京工業大学 情報理工学院 2018.04 休学 2018.07 退学
2019.03 Merpay Integration 2018.08 (サマーインターン) Merpay Integration 2018.09 - 2019.02 (内定者インターン) 退学旅行 2019.03 新卒入社 2019.04 New Customer Growth 2019.07 - 09 NewBiz 2019.10 - (Tech Lead)
6 • Merpay Integration (2018.08 - 2019.02) ◦ メルカリアプリへのメルペイ導入を行うチーム ▪
サイドメニュー撤廃 & 下タブ導入 ▪ マイページ追加 ▪ タイムラインUIの変更 ▪ その他、必要な作業すべて ... • (Sub) Developer Menu Rearchitecture ◦ 社内向けの開発者機能の Rearchitecture (後述) ◦ Objc-C && 1 Storyboard でやばかったので勝手にやった インターン時代 (2018.08 - 2019.02)
7 • New Customer Growth (2019.07 - 2019.09) ◦ 新規お客様向けの施策チーム
▪ 新規会員登録 ▪ 各種オンボーディング ▪ まだ A/B テスト段階のため、詳細は割愛 • NewBiz & Category (2019.10 - ) ◦ 新規領域の開拓やカテゴリ特化を行う施策チーム ▪ 絶賛新機能開発中 ◦ iOSのTech Lead 新卒入社後 (2019.04 -)
8 02 MercariにおけるiOS Engineer
9 • お客様に機能を届ける最後のまとめ役 ◦ どんなに良いUI DesignやMLのモデルがあっても クライアントアプリに落とし込まないとお客様へは届けられない ◦ スーパー大事 •
バックグラウンド・国籍は様々 ◦ 現在は全員で27人ほど (Mercari JPのみ) ◦ PR・Slack・Document 全てにおいて英語 iOS Engineerについて
10 チーム構成 mercari-ios Productivity Technical Problems Architect Client Feature1 Feature1
Feature1 Feature1 Feature N CI & CD
11 チーム構成 mercari-ios Productivity Technical Problems Architect Client Feature1 Feature1
Feature1 Feature1 Feature N CI & CD 20数人で同時に 開発、無理では
12 03 きらやばArchitectureとAutomation
13 03 きらやばArchitectureとAutomation
14 きらやばArchitecture = MVVM + μVC + Store (※僕が勝手にそう呼んでるだけです )
15 MVVM ViewController (VC) ViewModel Model
16 MVVM + μVC VC View Model Model View Model
View Model View Model VC VC VC
17 MVVM + μVC VC VC μVC μVC μVC VC
μVC μVC Component oriented architecture, like React
18 MVVM + μVC
19 • Rearchitectureチームの発足とコードベースの刷新 (2018年) ◦ iOSエンジニアが100人体制になっても スピードを落とさずに開発できるようなコードベースを作る ◦ 現在はその役割の一部を Architectチームが担う
◦ 共同開発でありがちな XIB(View)ファイルのconflictを見ることはほぼなくなった ◦ 事実として、現在20数人が同時に一つのアプリを開発できている => ✅成功 • 参考 ◦ メルカリJP初のiOSリアーキテクチャは、なぜ「最高に楽しい」のか ◦ MicroViewControllerで無限にスケールするiOS開発 - iOSDC 2018 MVVM + μVC
20 MVVM + μVC VM VM VM VM VM VM
VM VM State State State State State State State State Each VM has own State It’s hard to pass state changes to other VMs...
21 MVVM + μVC + Store Root VM VM VM
VM VM VM VM VM State Store Dispatcher Action Introduce Store like Flux own
22 Architectureの歴史 2013: Pure MVC (Objc-C) 2014: Pure MVC (Objc-C)
2015: Pure MVC, heading to MVVM (Objc-C) 2016: MVVM (Objc-C + Swift) 2017: MVVM (Objc-C + Swift) 2018: MVVM + μVC (Swift) 2019: MVVM + μVC + Store (Swift) 2020: heading to SwiftUI + Combine… Swift SwiftUI
23 きらやばArchitecture = MVVM + μVC + Store (※僕が勝手にそう呼んでるだけです )
24 03 きらやばArchitectureとAutomation
25 Automation 一ヶ月で約665 commitsが developに入る develop branchとのconflict解 決がやばいのでは
26 Automation (GitHub Label) • In House Dev ◦ 内製のバイナリ配布システムにより
commit されるたび自動配布 • Nightly Merge ◦ 自動的にdevelopのmergeを行うPRを毎 晩作成する • Auto Merge ◦ CIが終わり次第、自動で mergeする
27 • Nightly Merge + Auto Mergeの組み合わせが強力 ◦ CIがNightly Merge
PR作成時に、conflictがない場合は自動で mergeする ◦ 朝会社に来ると 「feature branchは既に最新のdevelop branchに追従した状態」になっている ◦ つまり、勝手にdevelop branchとの差分が解消されているため、 develop へ mergeする際 に大量のconflictが発生することがほとんどなくなる Automation (GitHub Label) 最高
28 • 最強のBotを社内で飼っている ◦ Binary Submit, App Release, Crash Report,
Distribute Binary, etc…. ◦ 諸般の事情により、その姿をお見せすることはまだできない。。。。 ◦ (最強すぎるため) Automation (Bot)
29 • Mercari iOSのコードベースは日々進化を遂げている ◦ 100人で同時に開発できるスケーラブルな Architectureを目指して ◦ 数々の技術的な挑戦が積み重なっている •
Automationもがんばってる ◦ GitHub Label系Automation ◦ 社内最強Bot ◦ 参考: Automation/karakuri for increasing engineering productivity - TechBlog • 最高に楽しい ◦ iOS Engineerとして、メルカリ iOSのコードベースや開発環境はとても刺激的 ◦ 技術で世界を殴っていきたい方、お待ちしております。 Wrap up