Skip to content

Commit

Permalink
Merge pull request karlseguin#9 from craiglittle/master
Browse files Browse the repository at this point in the history
Missing apostrophe
  • Loading branch information
Karl Seguin committed Mar 6, 2012
2 parents d0420ad + 84d8b12 commit 420359a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions en/mongodb.markdown
Expand Up @@ -110,7 +110,7 @@ First we'll use the global `use` method to switch databases, go ahead and enter

db.unicorns.insert({name: 'Aurora', gender: 'f', weight: 450})

The above line is executing `insert` against the `unicorns` collection, passing it a single argument. Internally MongoDB uses a binary serialized JSON format. Externally, this means that we use JSON a lot, as is the case with our parameters. If we execute `db.getCollectionNames()` now, we'll actually see two collections: `unicorns` and `system.indexes`. `system.indexes` is created once per database and contains the information on our databases index.
The above line is executing `insert` against the `unicorns` collection, passing it a single argument. Internally MongoDB uses a binary serialized JSON format. Externally, this means that we use JSON a lot, as is the case with our parameters. If we execute `db.getCollectionNames()` now, we'll actually see two collections: `unicorns` and `system.indexes`. `system.indexes` is created once per database and contains the information on our database's index.

You can now use the `find` command against `unicorns` to return a list of documents:

Expand Down Expand Up @@ -439,7 +439,7 @@ The message from this chapter is that MongoDB, in most cases, can replace a rela
\clearpage

## Chapter 6 - MapReduce ##
MapReduce is an approach to data processing which has two significant benefits over more traditional solutions. The first, and main, reason it was development is performance. In theory, MapReduce can be parallelized, allowing very large sets of data to be processed across many cores/CPUs/machines. As we just mentioned, this isn't something MongoDB is currently able to take advantage of. The second benefit of MapReduce is that you get to write real code to do your processing. Compared to what you'd be able to do with SQL, MapReduce code is infinitely richer and lets you push the envelope further before you need to use a more specialized solution.
MapReduce is an approach to data processing which has two significant benefits over more traditional solutions. The first, and main, reason it was developed is performance. In theory, MapReduce can be parallelized, allowing very large sets of data to be processed across many cores/CPUs/machines. As we just mentioned, this isn't something MongoDB is currently able to take advantage of. The second benefit of MapReduce is that you get to write real code to do your processing. Compared to what you'd be able to do with SQL, MapReduce code is infinitely richer and lets you push the envelope further before you need to use a more specialized solution.

MapReduce is a pattern that has grown in popularity, and you can make use of it almost anywhere; C#, Ruby, Java, Python and so on all have implementations. I want to warn you that at first this'll seem very different and complicated. Don't get frustrated, take your time and play with it yourself. This is worth understanding whether you are using MongoDB or not.

Expand Down

0 comments on commit 420359a

Please sign in to comment.