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
The things I've seen, living with MongoDB
Search
Bradley Whittington
October 03, 2013
Technology
150
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
The things I've seen, living with MongoDB
A short talk through some of the lessons learned about MongoDB at Motribe and Mxit
Bradley Whittington
October 03, 2013
More Decks by Bradley Whittington
See All by Bradley Whittington
Black Friday 2017 talk at Cape Town DevOps meetup
bradwhittington
0
49
Let's talk about Git
bradwhittington
0
99
Doing something new in an existing company culture
bradwhittington
0
140
Load Balancing 101
bradwhittington
1
510
Agile-ish is good enough
bradwhittington
1
580
PHP Addiction - or, teach someone about python
bradwhittington
2
670
Quick overview of MongoDB
bradwhittington
0
120
Other Decks in Technology
See All in Technology
制約理論(ToC)入門 2026版
recruitengineers
PRO
6
1.9k
サイバー捜査員研修(後半)
nomizone
1
780
今こそ聞きたいソフトウェア設計 ドメイン駆動設計再入門
masuda220
PRO
17
6.3k
第3回しろおびセキュリティスポンサーセッション
log0417
0
150
JavaScript 研修 (2026)
recruitengineers
PRO
1
410
生成 AI の基礎 〜 サンプル実装で学ぶ基本原理
enakai00
7
4.4k
ボトムアップ文化が強い組織で セキュリティをどう根付かせていくかの現在進行形の話 / Making Security Stick in a Bottom-Up Organization
yamaguchitk333
0
180
【CEDEC2026】『ウマ娘 プリティーダービー』 英語版のキャラクターの方言や口調をローカライズするための創造的アプローチ
cygames
PRO
1
190
Issue設計から始める仕様駆動開発 / 20260731 Mizuki Hirata
shift_evolve
PRO
1
140
Data Hubグループ 紹介資料
sansan33
PRO
0
3.1k
事業価値と Engineering 2026年度版
recruitengineers
PRO
41
21k
20260608_Codexの可能性_ノンプログラマー向け_大城追記
doradora09
PRO
0
770
Featured
See All Featured
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.7k
How to Talk to Developers About Accessibility
jct
2
490
GraphQLとの向き合い方2022年版
quramy
50
15k
Building AI with AI
inesmontani
PRO
1
1.1k
VelocityConf: Rendering Performance Case Studies
addyosmani
333
25k
Digital Ethics as a Driver of Design Innovation
axbom
PRO
1
360
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
610
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Breaking role norms: Why Content Design is so much more than writing copy - Taylor Woolridge
uxyall
0
360
The SEO identity crisis: Don't let AI make you average
varn
0
530
Building a Modern Day E-commerce SEO Strategy
aleyda
45
9.2k
Statistics for Hackers
jakevdp
799
230k
Transcript
The things I’ve seen, living with MongoDB Brad Whittington VP
web products - Mxit
What we use MongoDB for Primary data store for a
few consumer products. Motribe mobile social network - JudgeME & MxPix Mxit Launch
JudgeMe
None
Polytechnical university of hardknocks 1 week into my new job…
Zero MongoDB experience Massive crashes and timeouts on our cluster Hundreds of requests per minute
MongoDB docs == MongoDB + EC2 =
db.serverStatus() rs.add(...) MMS
MongoSQL? Mongo is *not* a relational database This is bad:
{ _id:... friend_id:... user_id:... }
The Data is Hot If you can’t fit all your
data in RAM, make sure you are kind to your (network connected) hard drives. Reads from (networked) disks are (incredibly) slow.
sort by rand() limit 1 MongoDB is all… One Solution!
(see the help pages for more) Add random geospatial positions Geospatial indexing Query for objects near [x,y] Disks are all like
I wish we had Capped Arrays*... Database with Capped Collections.Totally
okay. For the first n00 000 collections. Then it’s a bad idea. A very bad idea. * Available in MongoDB 2.4
A fresh start. Mxit Launch Platform for app creation Aim
for ±single document per request Cache cleverly, aggressively Database per app 300 authors 9M pageviews/month 2M unique users 4 m1.small 1 amazon core, 1.7GB ram
A fresh lesson Doing ensureIndex(..., {background:true}) inline in the request
is sub-optimal. 60 indexing processes 3M document collection (not fully in RAM) Not ideal.
db.currentOp() db.killOp() db.repair() db.currentOp().inprog.forEach( function(d){ if(d.waitingForLock && d.lockType != "read")
printjson(d) })
MongoDB Love • Mongo terminal is JS • Recovery is
quick, easy • Sharding is easy • Indexes are lovely • Be careful in your architecture / queries. Pure index queries are ++ • MongoDB is not a Relational DB
Read http://aphyr.com/tags/jepsen Aphyr / Jepsen / Call me maybe
@darb github.com/bradwhittington speakerdeck.com/u/bradwhittington/ Questions?