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
Architecture with NoSQL: Experiences of a SaaS ...
Search
lautis
August 21, 2012
Technology
4
700
Architecture with NoSQL: Experiences of a SaaS startup
Presentation at WICSA 2012 Industry day.
lautis
August 21, 2012
Tweet
Share
More Decks by lautis
See All by lautis
Real-Time with Flowdock
lautis
2
190
Other Decks in Technology
See All in Technology
UI State設計とテスト方針
rmakiyama
3
790
成果を出しながら成長する、アウトプット駆動のキャッチアップ術 / Output-driven catch-up techniques to grow while producing results
aiandrox
0
380
継続的にアウトカムを生み出し ビジネスにつなげる、 戦略と運営に対するタイミーのQUEST(探求)
zigorou
0
830
Qiita埋め込み用スライド
naoki_0531
0
5.3k
APIとはなにか
mikanichinose
0
110
re:Invent 2024 Innovation Talks(NET201)で語られた大切なこと
shotashiratori
0
320
なぜCodeceptJSを選んだか
goataka
0
180
10個のフィルタをAXI4-Streamでつなげてみた
marsee101
0
180
DevFest 2024 Incheon / Songdo - Compose UI 조합 심화
wisemuji
0
160
React Routerで実現する型安全なSPAルーティング
sansantech
PRO
2
280
[トレノケ雲の会 mod.13] 3回目のre:Inventで気づいたこと -CloudOperationsを添えて-
shintaro_fukatsu
0
110
LINE Developersプロダクト(LIFF/LINE Login)におけるフロントエンド開発
lycorptech_jp
PRO
0
150
Featured
See All Featured
Into the Great Unknown - MozCon
thekraken
33
1.5k
A Tale of Four Properties
chriscoyier
157
23k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
33
2k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
Making Projects Easy
brettharned
116
6k
Designing Experiences People Love
moore
138
23k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
159
15k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
59k
Six Lessons from altMBA
skipperchong
27
3.5k
Java REST API Framework Comparison - PWX 2021
mraible
28
8.3k
Being A Developer After 40
akosma
87
590k
Fireside Chat
paigeccino
34
3.1k
Transcript
Architecture with NoSQL Experiences of a SaaS startup Ville Lautanala
None
•Single page JavaScript front-end •Thousands of concurrent users •Three replicated
databases •X servers on two continents •99.98% availability Facts
Streaming API MongoDB Redis + IRC, Twitter, RSS, and Email
integrations WebSocket API Message Backend PostgreSQL Rails App
MongoDB • Document-oriented • JSON based queries • Scalable reads
and writes • Replication and failover built-in • No transactions, no JOINs
SSD == Awesome
None
Chef
Manage servers with code 1. Edit recipes 2. knife upload
3. ??? 4. Profit!!!
Redis: in-memory DB •Key-value store •Data-structure server •Network accessible shared
memory •Non-blocking event-bus (pub/sub)
Flowdock message processing Redis Queue Redis Pubsub MongoDB Flowdock Backend
Redis is SPoF
ZooKeeper
ZooKeeper? •Highly-available key-value store •Enables distributed coordination •Listen for value
changes •Eventual consistency with quorum semantics
Node Manager Node Manager Redis Node Redis Node ZooKeeper Monitor
Update Redis Failover
Zoos are kept.
Chef ZooKeeper Configuration files Dynamic configuration variables Server installation Failover
handling Chef vs ZooKeeper
Network fail Flowdock Comcast Problems
Taking control of the routes 1. Submarine communications cable 2.
3rd party CDN/Load Balancers 3. AWS as SSL endpoint
This Is How We Roll •GeoDNS chooses endpoint •Encrypted VPN
mesh between servers •Servers near client act as SSL endpoint •Request processed near data
150ms faster page requests from U.S.
Conclusions •MongoDB a bit like MySQL 15 years ago •Some
NoSQL databases are suitable for distributed setups •Hardware and network issues needs to be addressed
Thanks!