Skip to main content
main-content

Über dieses Buch

MongoDB, a cross-platform NoSQL database, is the fastest-growing new database in the world. MongoDB provides a rich document-oriented structure with dynamic queries that you’ll recognize from RDBMS offerings such as MySQL. In other words, this is a book about a NoSQL database that does not require the SQL crowd to re-learn how the database world works!

MongoDB has reached 1.0 and boasts 50,000+ users. The community is strong and vibrant and MongoDB is improving at a fast rate. With scalable and fast databases becoming critical for today’s applications, this book shows you how to install, administer and program MongoDB without pretending SQL never existed.

Inhaltsverzeichnis

Frontmatter

Basics

Frontmatter

Chapter 1. Introduction to MongoDB

Imagine a world where using a database is so simple that you soon forget you’re even using it. Imagine a world where speed and scalability just work, and there’s no need for complicated configuration or setup. Imagine being able to focus only on the task at hand, get things done, and then—just for a change—leave work on time. That might sound a bit fanciful, but MongoDB promises to help you accomplish all these things (and many more).

Chapter 2. Installing MongoDB

In Chapter 1, you got a taste of what MongoDB can do for you. In this chapter, you will learn how to install and expand MongoDB even further, enabling you to use it in combination with your favorite programming language.

Chapter 3. The Data Model

In the previous chapter, you learned how to install MongoDB on two commonly used platforms (Windows and Linux), as well as how to extend the database with some additional drivers. In this chapter, you will shift your attention from the operating system and instead examine the general design of a MongoDB database. Specifically, you’ll learn what collections are; what documents look like; how indexes work and what they do; and finally, when and where to reference data instead of embedding data. We touched on some of these concepts briefly in Chapter 1. To refresh your memory though, we’ll address some of this material again in this chapter, but this time in more detail. Throughout this chapter, you will see code examples designed to give you get a good feel of what is being discussed. Do not worry too much about the commands you’ll be looking at, however, because they will be discussed extensively in Chapter 4.

Chapter 4. Working with Data

In the previous chapter, you learned how the database works on the backend, what indexes are, how to use a database to quickly find the data you are looking for, and what the structure of a document looks like. You also saw a brief example that illustrated how to add data and find it again using the MongoDB shell. In this chapter, we will focus more on working with the data from your shell.

Chapter 5. GridFS

We live in a world of high definition video, 12MP cameras, and storage media that can hold 50GB of data on a disc the size of a CDROM. In that context, the 4MB limit for the maximum size of a MongoDB document might seem laughably inadequate. Indeed, you might wonder why MongoDB, which has been designed as a database for today’s high-tech age, has such a strange limitation. The short answer: performance.

Developing

Frontmatter

Chapter 6. PHP and MongoDB

Through the first five chapters, you’ve learned how to perform all sorts of actions in the MongoDB shell. For example, you’ve learned how to add, modify, and delete a document. You’ve also learned about the workings of DBRef and GridFS, including how to use them.

Chapter 7. Python and MongoDB

Python is by far one of the easier programming languages to learn and master. It’s an especially great language to start with if you are relatively new to programming. And you’ll pick it up that much more quickly if you’re already quite familiar with programming.

Chapter 8. Creating a Blog Application with the PHP Driver

In the previous pair of chapters, we discussed how to use MongoDB to store all sorts of data, as well as how to update data in a MongoDB database. We also covered a pair of drivers that you can use to extend MongoDB: the PHP driver and the Python driver.

Advanced

Frontmatter

Chapter 9. Database Administration

In this chapter, we will walk you through some of the basic administrative operations you can perform on a MongoDB server. We will also show you how to automate some of those activities, such as backing up your server.

Chapter 10. Optimization

There is a tongue-in-cheek statement about MongoDB attributed to an unknown Twitter user: “If a MongoDB query runs for longer than 0ms, then something is wrong.” This is typical of the kind of buzz that surrounded the product when it first burst onto the scene about a year ago.

Chapter 11. Replication

Like many of its relational cousins, MongoDB supports the replication of a database’s contents to another server in realtime or near realtime. MongoDB’s replication features are simple to set up and use. They are also one of the key features in MongoDB that bolster the claim that the database is both a Web 2.0 and a cloud-based datastore.

Chapter 12. Sharding

Whether you’re building the next Facebook or just a simple database application, you will probably need to scale your app up at some point if it’s successful. If you don’t want to be continually replacing your hardware, then you will want to use a technique that allows you to add capacity incrementally to your system, as you need it. Sharding is a technique that allows you to spread your data across multiple machines, yet does so in a way that mimics an app hitting a single database.

Backmatter

Weitere Informationen

Premium Partner

BranchenIndex Online

Die B2B-Firmensuche für Industrie und Wirtschaft: Kostenfrei in Firmenprofilen nach Lieferanten, Herstellern, Dienstleistern und Händlern recherchieren.

Whitepaper

- ANZEIGE -

Best Practices für die Mitarbeiter-Partizipation in der Produktentwicklung

Unternehmen haben das Innovationspotenzial der eigenen Mitarbeiter auch außerhalb der F&E-Abteilung erkannt. Viele Initiativen zur Partizipation scheitern in der Praxis jedoch häufig. Lesen Sie hier  - basierend auf einer qualitativ-explorativen Expertenstudie - mehr über die wesentlichen Problemfelder der mitarbeiterzentrierten Produktentwicklung und profitieren Sie von konkreten Handlungsempfehlungen aus der Praxis.
Jetzt gratis downloaden!

Bildnachweise