MTV Networks owns and operates hundreds of high-traffic web properties, including spike.com, gametrailers.com, thedailyshow.com, comedycentral.com, and nick.com. These properties evolved independently using a variety of languages, frameworks, and data models. MTV chose MongoDB as the data store for a new unified Java-based content management system (CMS), taking advantage of its document data model and flexible schema.
MTV’s web properties were originally built on a commercial, Java-based content management system that forced their rich documents into an ill-suited data model. The team evaluated migrating to a relational model for a new CMS, but the diversity of web properties posed a major roadblock. Adding new data types and tables to the schema significantly dampened read performance and other operations. After struggling with this architecture, which limited the evolution and success of their system, MTV began looking for a database solution that could grow, scale, and represent data flexibly as they brought additional content brands onto the platform.
MongoDB's document storage model allows MTV to store hierarchical data (like TV episodes within a series) easily, without requiring expensive queries to build pages. MongoDB’s inherently flexible schema allows MTV to concisely model the structures and data elements required by each brand.
Queries and Indexing
The rich querying capabilities of MongoDB provided a combination of features unavailable in pure key-value stores, RDBMS or the previous system. No other databases provides an efficient way to query nested content -- a hallmark of a document schema. MTV found querying nested data in MongoDB easy to understand and incredibly fast.
With their previous system, all data fields had to be indexed regardless of whether they were ever queried. This led to significant wasted storage space, and unnecessary latency during updates. With MongoDB MTV can build indexes selectively, achieving high query performance and efficient use of space.
Ease of Operations
The MTV team has deep experience developing for and operating relational technologies, and found that this knowledge mapped well to MongoDB. The previously deployed system was difficult to cluster, requiring shared disk storage for all cluster members. In contrast, MTV found MongoDB’s replica sets, which do not required shared disk storage, far simpler to scale via database clustering. With replica sets, each MongoDB server acts independently, and requires only local storage.
According to Jeff Yemin of MTV, "From an operational perspective, [MongoDB] feels very much like MySQL, so our systems and DBA groups are quite comfortable managing the deployment."
MongoDB's document data model enabled MTV's content management team to build a solution that can meet the needs of each of their web properties generically, while simplifying day to day operations. This lets the development team focus on building features for the end user instead of back-end storage.