Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
HOW I LEARNED TO   STOP WORRYING ANDLOVE THE DOCUMENT STORE       COREY EHMKE
IN A PREVIOUS LIFE...BUILDING A PPC LANDING PAGE HOSTING PLATFORMINTERACTION-LEVEL ANALYTICSA/B AND MULTIVARIATE TESTINGDY...
DOES THIS SOUND FAMILIAR?MODELS CONSTANTLY EVOLVING IN RESPONSE TO ILL-DEFINED REQUIREMENTS AND CHANGING NEEDSPOLYMORPHIC ...
ACTIVE RECORD:      THE WRONG HAMMERBIG DATA = PAINFUL MIGRATIONSRAKE TASKS TO MANAGE DATA TRANSFORMATIONSSINGLE TABLE INH...
JAMIE ZAWINSKI“YOU NEVER KNOW WHAT THE DESIGN IS    UNTIL THE PROGRAM IS DONE.”
IN SHORT...   ACTIVE RECORD AND SQLJUST DON’T FEEL AGILE ENOUGH.
MONGODB TO THE RESCUEDOCUMENT MODEL ALLOWS FOR THE EASY ADDITION OFNEW FIELDSEMBEDDED COLLECTIONSBUILT-IN VERSIONINGMAP RE...
THE DESIGN PHILOSOPHYDATA MODELS SHOULD BE EASY TO CODE, EASY TOMANAGE, AND HIGHLY PERFORMANTDATABASES SHOULD BE ABLE TO S...
STRENGTHSFLEXIBILITY  JSON-LIKE DOCUMENT STORAGE  SUPPORT FOR NATIVE TYPES  SCHEMA-LESS
STRENGTHSPOWER DYNAMIC QUERIES UPSERTS EASY AGGREGATION VIA MAP-REDUCE
STRENGTHSSPEED NO JOINS! AUTO-SHARDING TO INCREASE CAPACITY WITHOUT DOWNTIME
WEAKNESSESLACK OF MATURE GUI TOOLSNO FINE-GRAINED TUNINGNO MULTI-DOCUMENT TRANSACTIONS
PRACTICAL CONSIDERATIONSSTOP THINKING IN TABLES, START THINKING INDOCUMENTSEMBEDDED COLLECTIONS, BUT USE CAREFULLYFULLY CA...
MONGOIDMY OBJECT-DOCUMENT-MAPPER (ODM) OF CHOICEACTIVEMODEL MAKES MONGOID DOCUMENTSFIRST-CLASS CITIZENS IN RAILSPARTIAL UP...
MONGODB AT TRUNK CLUB
NO SCHEMA, NO MIGRATIONS
NICE QUERY YOU HAVE THERE
OPERATORS IN SCOPES
EMBED THOSE PUPPIES
DOES THIS LOOK FAMILIAR?
HELL YEAH PERFORMANCE1,000,000 DOCUMENTS2.93 GHZ IMAC WITH 8GB RAMMODEL#CREATE: 2,392 / SECONDMODEL#UPDATE_ATTRIBUTE: 2,94...
EVERYTHING JUST WORKSSCOPESCALLBACKSREFERENCED RELATIONSOBSERVERSVALIDATIONSINDEXES
USE CASESBIG DATA(LOGS, ANYONE?)COMPLEX QUERIES(MAP REDUCE IS YOUR FRIEND)RAPIDLY EVOLVING MODELSLIBERAL USE OF JSONRELATI...
DON’T USE IT IF...YOU’RE WORKING WITH COMPLEX TRANSACTIONSYOU’RE WORKING WITH MISSION-CRITICAL DATAYOU ENJOY WRITING RAW S...
Upcoming SlideShare
Loading in …5
×

How I Learned to Stop Worrying and Love the Document Store

381 views

Published on

Published in: Technology
  • Be the first to comment

  • Be the first to like this

How I Learned to Stop Worrying and Love the Document Store

  1. 1. HOW I LEARNED TO STOP WORRYING ANDLOVE THE DOCUMENT STORE COREY EHMKE
  2. 2. IN A PREVIOUS LIFE...BUILDING A PPC LANDING PAGE HOSTING PLATFORMINTERACTION-LEVEL ANALYTICSA/B AND MULTIVARIATE TESTINGDYNAMIC PAGE CONTENTREQUIREMENT FOR REAL-TIME REPORTING
  3. 3. DOES THIS SOUND FAMILIAR?MODELS CONSTANTLY EVOLVING IN RESPONSE TO ILL-DEFINED REQUIREMENTS AND CHANGING NEEDSPOLYMORPHIC REPRESENTATIONS OF USERINTERACTIONSVERSIONING TO SUPPORT MULTIVARIATE TESTINGREQUIREMENTSNEED TO QUICKLY SCALE UP IN RESPONSE TO DEMAND
  4. 4. ACTIVE RECORD: THE WRONG HAMMERBIG DATA = PAINFUL MIGRATIONSRAKE TASKS TO MANAGE DATA TRANSFORMATIONSSINGLE TABLE INHERITANCE NIGHTMARECHALLENGE OF SCALING UP A SQL DATABASE
  5. 5. JAMIE ZAWINSKI“YOU NEVER KNOW WHAT THE DESIGN IS UNTIL THE PROGRAM IS DONE.”
  6. 6. IN SHORT... ACTIVE RECORD AND SQLJUST DON’T FEEL AGILE ENOUGH.
  7. 7. MONGODB TO THE RESCUEDOCUMENT MODEL ALLOWS FOR THE EASY ADDITION OFNEW FIELDSEMBEDDED COLLECTIONSBUILT-IN VERSIONINGMAP REDUCE FOR FAST DATA AGGREGATIONSCALING IS EASY
  8. 8. THE DESIGN PHILOSOPHYDATA MODELS SHOULD BE EASY TO CODE, EASY TOMANAGE, AND HIGHLY PERFORMANTDATABASES SHOULD BE ABLE TO SCALEHORIZONTALLY WITH EASE
  9. 9. STRENGTHSFLEXIBILITY JSON-LIKE DOCUMENT STORAGE SUPPORT FOR NATIVE TYPES SCHEMA-LESS
  10. 10. STRENGTHSPOWER DYNAMIC QUERIES UPSERTS EASY AGGREGATION VIA MAP-REDUCE
  11. 11. STRENGTHSSPEED NO JOINS! AUTO-SHARDING TO INCREASE CAPACITY WITHOUT DOWNTIME
  12. 12. WEAKNESSESLACK OF MATURE GUI TOOLSNO FINE-GRAINED TUNINGNO MULTI-DOCUMENT TRANSACTIONS
  13. 13. PRACTICAL CONSIDERATIONSSTOP THINKING IN TABLES, START THINKING INDOCUMENTSEMBEDDED COLLECTIONS, BUT USE CAREFULLYFULLY CAPABLE OF TRADITIONAL RELATIONSNO SCHEMAS, NO MIGRATIONSNO SQL (USE JAVASCRIPT)
  14. 14. MONGOIDMY OBJECT-DOCUMENT-MAPPER (ODM) OF CHOICEACTIVEMODEL MAKES MONGOID DOCUMENTSFIRST-CLASS CITIZENS IN RAILSPARTIAL UPDATES (CHANGED FIELDS ONLY)CHAINABLE, LAZY-EVALUATED QUERIES VIA CRITERIA
  15. 15. MONGODB AT TRUNK CLUB
  16. 16. NO SCHEMA, NO MIGRATIONS
  17. 17. NICE QUERY YOU HAVE THERE
  18. 18. OPERATORS IN SCOPES
  19. 19. EMBED THOSE PUPPIES
  20. 20. DOES THIS LOOK FAMILIAR?
  21. 21. HELL YEAH PERFORMANCE1,000,000 DOCUMENTS2.93 GHZ IMAC WITH 8GB RAMMODEL#CREATE: 2,392 / SECONDMODEL#UPDATE_ATTRIBUTE: 2,945 / SECONDMODEL.ALL#EACH: 2,325 / SECOND
  22. 22. EVERYTHING JUST WORKSSCOPESCALLBACKSREFERENCED RELATIONSOBSERVERSVALIDATIONSINDEXES
  23. 23. USE CASESBIG DATA(LOGS, ANYONE?)COMPLEX QUERIES(MAP REDUCE IS YOUR FRIEND)RAPIDLY EVOLVING MODELSLIBERAL USE OF JSONRELATIONS THAT WANT TO BE EMBEDDED(E.G. ORDERS <=> LINE ITEMS)
  24. 24. DON’T USE IT IF...YOU’RE WORKING WITH COMPLEX TRANSACTIONSYOU’RE WORKING WITH MISSION-CRITICAL DATAYOU ENJOY WRITING RAW SQLYOU NEED TO QUICKLY PULL DATA OUT INTO A CSVYOU’RE AFRAID OF NEW THINGS

×