MongoDB: The Definitive Guide

Powerful and Scalable Data Storage

Kristina Chodorow, Michael Dirolf

Publisher: O'Reilly, 2010, 193 pages

ISBN: 978-1-449-38156-1

Keywords: Databases

Last modified: March 1, 2013, 12:59 a.m.

How does MongoDB help you manage a huMONGOus amount of data collected through your web application? With this authoritative introduction, you'll learn the many advantages of using document-oriented databases, and discover why MongoDB is a reliable, high-performance system that allows for almost infinite horizontal scalability.

Written by engineers from 10gen, the company that develops and supports this open source database, MongoDB: The Definitive Guide provides guidance for database developers, advanced configuration for system administrators, and an overview of the concepts and use cases for other people on your project. Learn how easy it is to handle data as self-contained JSON-style documents, rather than as records in a relational database.

  • Explore ways that document-oriented storage will work for your project
  • Learn how MongoDB’s schema-free data model handles documents, collections, and multiple databases
  • Execute basic write operations, and create complex queries to find data with any criteria
  • Use indexes, aggregation tools, and other advanced query techniques
  • Learn about monitoring, security and authentication, backup and repair, and more
  • Set up master-slave and automatic failover replication in MongoDB
  • Use sharding to scale MongoDB horizontally, and learn how it impacts applications
  • Get example applications written in Java, PHP, Python, and Ruby
  1. Introduction
    • A Rich Data Model
    • Easy Scaling
    • Tons of Features…
    • …Without Sacrificing Speed
    • Simple Administration
    • But Wait, That's Not All…
  2. Getting Started
    • Documents
    • Collections
      • Schema-Free
      • Naming
    • Databases
    • Getting and Starting MongoDB
    • MongoDB Shell
      • Running the Shell
      • A MongoDB Client
      • Basic Operations with the Shell
      • Tips for Using the Shell
    • Data Types
      • Basic Data Types
      • Numbers
      • Dates
      • Arrays
      • Embedded Documents
      • _id and ObjectIds
  3. Creating, Updating, and Deleting Documents
    • Inserting and Saving Documents
      • Batch Insert
      • Inserts: Internals and Implications
    • Removing Documents
      • Remove Speed
    • Updating Documents
      • Document Replacement
      • Using Modifiers
      • Upserts
      • Updating Multiple Documents
      • Returning Updated Documents
    • The Fastest Write This Side of Mississippi
      • Safe Operations
      • Catching "Normal" Errors
    • Requests and Connections
  4. Querying
    • Introduction to find
      • Specifying Which Keys to Return
      • Limitations
    • Query Criteria
      • Query Conditionals
      • OR Queries
      • $not
      • Rules for Conditionals
    • Type-Specific Queries
      • null
      • Regular Expressions
      • Querying Arrays
      • Querying on Embedded Documents
    • $where Queries
    • Cursors
      • Limits, Skips, and Sorts
      • Avoiding Large Skips
      • Advanced Query Options
      • Getting Consistent Results
    • Cursor Internals
  5. Indexing
    • Introduction to Indexing
      • Scaling Indexes
      • Indexing Keys in Embedded Documents
      • Indexing for Sorts
      • Uniquely Identifying Indexes
    • Unique Indexes
      • Dropping Duplicates
      • Compound Unique Indexes
    • Using explain and hint
    • Index Administration
      • Changing Indexes
    • Geospatial Indexing
      • Compound Geospatial Indexes
      • The Earth Is Not a 2D Plane
  6. Aggregation
    • count
    • distinct
    • group
      • Using a Finalizer
      • Using a Function as a Key
    • MapReduce
      • Example 1: Finding All Keys in a Collection
      • Example 2: Categorizing Web Pages
      • MongoDB and MapReduce
  7. Advanced Topics
    • Database Commands
      • How Commands Work
      • Command Reference
    • Capped Collections
      • Properties and Use Cases
      • Creating Capped Collections
      • Sorting Au Naturel
      • Tailable Cursors
    • GridFS: Storing Files
      • Getting Started with GridFS: mongofiles
      • Working with GridFS from the MongoDB Drivers
      • Under the Hood
    • Server-Side Scripting
      • db.eval
      • Stored JavaScript
      • Security
    • Database References
      • What Is a DBRef?
      • Example Schema
      • Driver Support for DBRefs
      • When Should DBRefs Be Used?
  8. Administration
    • Starting and Stopping MongoDB
      • Starting from the Command Line
      • File-Based Configuration
      • Stopping MongoDB
    • Monitoring
      • Using the Admin Interface
      • serverStatus
      • mongostat
      • Third-Party Plug-Ins
    • Security and Authentication
      • Authentication Basics
      • How Authentication Works
      • Other Security Considerations
    • Backup and Repair
      • Data File Backup
      • mongodump and mongorestore
      • fsync and Lock
      • Slave Backups
      • Repair
  9. Replication
    • Master-Slave Replication
      • Options
      • Adding and Removing Sources
    • Replica Sets
      • Initializing a Set
      • Nodes in a Replica Set
      • Failover and Primary Election
    • Performing Operations on a Slave
      • Read Scaling
      • Using Slaves for Data Processing
    • How It Works
      • The Oplog
      • Syncing
      • Replication State and the Local Database
      • Blocking for Replication
    • Administration
      • Diagnostics
      • Changing the Oplog Size
      • Replication with Authentication
  10. Sharding
    • Introduction to Sharding
    • Autosharding in MongoDB
      • When to Shard
    • The Key to Sharding: Shard Keys
      • Sharding an Existing Collection
      • Incrementing Shard Keys Versus Random Shard Keys
      • How Shard Keys Affect Operations
    • Setting Up Sharding
      • Starting the Servers
      • Sharding Data
    • Production Configuration
      • A Robust Config
      • Many mongos
      • A Sturdy Shard
      • Physical Servers
    • Sharding Administration
      • config Collections
      • Sharding Commands
  11. Example Applications
    • Chemical Search Engine: Java
      • Installing the Java Driver
      • Using the Java Driver
      • Schema Design
      • Writing This in Java
      • Issues
    • News Aggregator: PHP
      • Installing the PHP Driver
      • Using the PHP Driver
      • Designing the News Aggregator
      • Trees of Comments
      • Voting
    • Custom Submission Forms: Ruby
      • Installing the Ruby Driver
      • Using the Ruby Driver
      • Custom Form Submission
      • Ruby Object Mappers and Using MongoDB with Rails
    • Real-Time Analytics: Python
      • Installing PyMongo
      • Using PyMongo
      • MongoDB for Real-Time Analytics
      • Schema
      • Handling a Request
      • Using Analytics Data
      • Other Considerations
  1. Installing MongoDB
  2. mongo: The Shell
  3. MongoDB Internals

Reviews

MongoDB: The Definitive Guide

Reviewed by Roland Buresund

OK ***** (5 out of 10)

Last modified: March 1, 2013, 12:59 a.m.

This is more of a short introduction to MongoDB than a "definitive guide". It is an OK read, but nothing to get excited about.

Comments

There are currently no comments

New Comment

required

required (not published)

optional

required

captcha

required