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
Cookpad and Microservices
Search
taiki45
December 18, 2014
Programming
4.2k
4
Share
Cookpad and Microservices
at 第1回 えびスタ! ~ 恵比寿スタートアップ勉強会 ~
http://ebista.connpass.com/event/10258/
taiki45
December 18, 2014
More Decks by taiki45
See All by taiki45
Mocking in Rust Applications
taiki45
2
740
Error Handling in Rust Applications
taiki45
3
830
Efficient Platform for Security and Compliance
taiki45
6
1.7k
RustでAWS Lambda functionをいい感じに書く
taiki45
2
840
SPIFFE Meetup Tokyo #2 LT: Envoy SDS
taiki45
0
840
builderscon Tokyo 2019: Intro Service Mesh
taiki45
6
3.7k
NoOps Meetup Tokyo #7: 入門サービスメッシュ
taiki45
4
2k
CloudNative Days Tokyo 2019: Understanding Envoy
taiki45
3
3.6k
Cloud Native Meetup Tokyo #8 ServiceMesh Day Recap
taiki45
2
420
Other Decks in Programming
See All in Programming
ふりがな Deep Dive try! Swift Tokyo 2026
watura
0
250
第3木曜LT会 #28
tinykitten
PRO
0
120
UIの境界線をデザインする | React Tokyo #15 メイントーク
sasagar
2
400
Lightning-Fast Method Calls with Ruby 4.1 ZJIT / RubyKaigi 2026
k0kubun
3
1.9k
Liberating Ruby's Parser from Lexer Hacks
ydah
2
2.3k
〜バイブコーディングを超えて〜 チームで実験し続けたAI駆動開発
tigertora7571
0
180
ついに来た!本格的なマルチクラウド時代の Google Cloud
maroon1st
0
300
リセットCSSを1行消したらアクセシビリティが向上した話
pvcresin
1
170
2026-04-15 Spring IO - I Can See Clearly Now
jonatan_ivanov
1
140
ハーネスエンジニアリングとは?
kinopeee
13
6.4k
tRPCの概要と少しだけパフォーマンス
misoton665
2
250
2026年のソフトウェア開発を考える(2026/05版) / Software Engineering Scrum Fest Niigata 2026 Edition
twada
PRO
15
4.8k
Featured
See All Featured
Art, The Web, and Tiny UX
lynnandtonic
304
21k
The Limits of Empathy - UXLibs8
cassininazir
1
320
No one is an island. Learnings from fostering a developers community.
thoeni
21
3.7k
Evolving SEO for Evolving Search Engines
ryanjones
0
180
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4k
Joys of Absence: A Defence of Solitary Play
codingconduct
1
350
Unsuck your backbone
ammeep
672
58k
世界の人気アプリ100個を分析して見えたペイウォール設計の心得
akihiro_kokubo
PRO
70
39k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
25
1.9k
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
270
Producing Creativity
orderedlist
PRO
348
40k
Transcript
Cookpad and Microservices Why and how we move to Microservices
architecture style
Taiki Ono • @taiki45 • Joined Cookpad at 2014/3 •
Dev-Infra group • Working with service integration related things and Web API
Sponsored by
Hi, we are Cookpad
None
over 50M users/month over 1.8M recipes
Not only recipe site…
None
None
None
You can see more products!
To make everyday cooking fun.
Why Microservices?
• Environment changes • Limit of Monolithic
• Environment changes • Limit of Monolithic
Our business changes
User agent changes
• Environment changes • Limit of Monolithic
A huge Rails app +----------------------+-------+-------+---------+---------+-----+-------+ | Name | Lines |
LOC | Classes | Methods | M/C | LOC/M | +----------------------+-------+-------+---------+---------+-----+-------+ | Controllers | 46173 | 37194 | 493 | 3754 | 7 | 7 | | Helpers | 14251 | 11687 | 13 | 1367 | 105 | 6 | | Models | 10153 | 7799 | 319 | 1152 | 3 | 4 | | Mailers | 402 | 326 | 16 | 35 | 2 | 7 | | Javascripts | 40217 | 34405 | 36 | 4940 | 137 | 4 | | Libraries | 2341 | 1833 | 112 | 252 | 2 | 5 | | Async_view specs | 247 | 212 | 0 | 0 | 0 | 0 | | Controller specs | 58856 | 48671 | 7 | 121 | 17 | 400 | | Feature specs | 40886 | 33590 | 0 | 196 | 0 | 169 | | Helper specs | 4151 | 3396 | 1 | 10 | 10 | 337 | | Lib specs | 22537 | 18817 | 27 | 128 | 4 | 145 | | Mailer specs | 421 | 346 | 0 | 0 | 0 | 0 | | Model specs | 71128 | 58668 | 4 | 70 | 17 | 836 | | Policy specs | 1487 | 1219 | 0 | 0 | 0 | 0 | | Request specs | 34595 | 29677 | 0 | 12 | 0 | 2471 | | Routing specs | 661 | 533 | 0 | 0 | 0 | 0 | | View specs | 619 | 508 | 0 | 2 | 0 | 252 | | Worker specs | 862 | 715 | 0 | 1 | 0 | 713 | +----------------------+-------+-------+---------+---------+-----+-------+ | Total | 349987 | 289596 | 1028 | 12040 | 11 | 22 | +----------------------+-------+-------+---------+---------+-----+-------+
Slow test issue
RRRSpec solved
Slow deployment
mamiya solved
and some difficulties like scaling, upgrading Rails, etc…
We can’t control our own application.
We've found Microservices while we were challenging these issues.
Microservices
–James Lewis & Martin Fowler “an approach to developing a
single application as a suite of small services” IUUQNBSUJOGPXMFSDPNBSUJDMFTNJDSPTFSWJDFTIUNM
Build around business capabilities
None
Own process and lightweight messaging
HTTP JSON REST
Decentralization and polyglot
Ruby + MySQL Go + Redshift Java + MySQL
Characteristics of Microservices • Build around business capabilities • Own
process and lightweight messaging • Decentralization and polyglot
We can handle our own application, by paying cost of
complexity as a whole.
In Cookpad What we did?
Published service data
Garage Garage Garage Rails app
Garage and garage-client • RESTful hyper-media API • JSON message
enveloped in HTTP • Implemented as a Rails extension • Standardized communication pattern
Solutions for product common problems
º
̋
Backend products • Auth server (OAuth2.0) • Personal information server
• Notification base • Video backend
Data synchronization between products
Pub-Sub Topic
Pub-Sub Topic
Ping • Pub-Sub pattern • Implemented as a Rails extension
• A thin wrapper of Amazon SNS and fluentd • Receive events via webhook
What we did are… • Published product data with Garage
• Built some backend products • Built Ping for data synchronization
We are challenging more problems around Microservices
Join us!! http://recruit.cookpad.com/