This is where coaches spend much of their time reviewing and analyzing video. Below is a screenshot of our ‘Library’ page. So, we looked at how our application interacted with SQL and created an optimized schema in MongoDB.īefore I get into the schema we chose, I’ll try to provide context to Hudl’s product.
#Adding colums to hudl app code
In the NoSQL world joins are not an option and we knew that simply moving the SQL tables directly over to MongoDB and doing joins in code was a bad idea. Pulling together data from multiple tables is SQL’s bread-and-butter. In SQL Server we normalized our data model. In this post we’ll take a look at our schema design choices, our migration plan and the performance we’ve seen with MongoDB. We also wanted to have fail-safes ready during each step of the process so we could recover immediately from any unanticipated problems during the migration. We wanted to migrate the dataset with zero downtime and zero data loss. During our busy season we average 75 clip views per second but peak at over 800 per second. Video clips were not only our biggest dataset, it was also our most frequently-accessed data. Then came the task of moving our existing data from SQL Server to MongoDB. We wanted something that was fast, flexible and developer-friendly.Īfter comparing a few alternative NoSQL databases and running our own benchmarks, we settled on MongoDB. That’s when we began to look at NoSQL seriously and specifically MongoDB. Because we run in EC2, vertically scaling our DB was not a great option. After a few years and solid company growth we realized SQL Server was quickly becoming a bottleneck. Our backend is written primarily in C#, so it was a natural choice. When we began hacking away on Hudl we chose SQL Server as our database. From our first year of a dozen beta high schools we’ve grown to service the video needs of over 50,000 sports teams worldwide. Our clips dataset has grown to over 350GB of data with over 70GB of indexes. Today we store well over 600 million video clips in MongoDB spread across seven shards.
We give sports teams from peewee to the pros online tools to make working with and analyzing video easy. Hudl’s CTO, Brian Kaiser, will be speaking at MongoDB World about migrating from SQL Server to MongoDB This is a guest post by Jon Dokulil, VP of Engineering at Hudl.