Your SlideShare is downloading. ×
Mongo gotchas
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Introducing the official SlideShare app

Stunning, full-screen experience for iPhone and Android

Text the download link to your phone

Standard text messaging rates apply

Mongo gotchas

886
views

Published on

Published in: Technology, Education

0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
886
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
2
Comments
0
Likes
1
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Mongo  Gotchas   by  Billy  Chasen  Founder,  CEO  turntable.fm   @billychasen  
  • 2. video  www.youtube.com/watch?v=shgHA7lKJaY  
  • 3. How  we  use  mongo  •  All  turntable  room  state  in  mongo  •  All  persistent  data  •  Logging  (use  safe  =  False)  •  Incredibly  fast,  make  sure  you  give  it  enough   RAM  
  • 4. ConnecPons  •  The  magic  number  819   –  Depends  on  open  file  limits   –  Throws  a  vague  cannot  connect  to  primary/slave   error  
  • 5. Threads  •  CauPon  when  using  pymongo  with  Tornado  •  Use  libraries  like  async  mongo  for  Tornado  
  • 6. Indexes  •  Important!    Analyze  every  query  you  use  with   explain()  and  monitor  slow  query  log  
  • 7. OpPmize  returned  data  •  If  you  have  large  objects,  request  only  needed   fields  •  It’s  like  using  SELECT  uid,name  FROM  user  
  • 8. We’re  hiring!  •  jobs@turntable.fm  •  VP  Tech  •  Sysops