MongoDB for Developers with Python Transcripts
Chapter: Mapping classes to MongoDB with the ODM MongoEngine
Lecture: The dealership demo

Login or purchase this course to watch this video and the rest of the course contents.
0:00 So far, we've been kind of poking at MongoDB,
0:03 playing around with some of maybe existing data
0:05 or creating simple little databases with one or two records in it.
0:09 We're kind of done with that, we're ready to move on
0:11 to be building the main application that we're going to build for this course.
0:15 So we're going to take this concept of a car dealership
0:18 that does service for autos, sells cars, does service like engine repair,
0:23 fixes flat tires and so on, for a Ferrari dealership,
0:26 and that's going to be our demo for the rest of this course.
0:29 On this first go round, we're going to start out
0:32 with an empty database or a non-existent database,
0:34 we're going to model it in MongoDB with MongoEngine
0:38 and then we're going to run that code and create a few simple cars,
0:41 a couple Ferraries, maybe associate the cars with some owners,
0:45 do some service on the cars, somebody over rev the engine
0:48 and has got to get a new engine, or got a flat tire,
0:51 things like that; we'll see how it all works.
0:53 Later, when we get to the high performance section,
0:55 we're going to instead of start with an empty database
0:57 start with one with like a quarter million cars and tons and tons of service records
1:02 and they will start asking really interesting questions
1:05 and really focus on the performance side of things.
1:08 So we're going to use this for the rest of our time
1:10 and I have been really waiting till we got to the MongoEngine section
1:13 to create what I would think of as a somewhat realistic complex demo
1:17 because with PyMongo it's fine, but you'll see the real power of modeling this
1:21 in a full featured realistic production style way
1:25 once we get to MongoEngine things like indexes and uniqueness,
1:29 and constraints and types and lots of good stuff.
1:32 So I hope you're ready to learn MongoEngine,
1:34 and put it to work building this cool Ferrari dealership.