Schema Design Anti-Patterns - Part 1

Ғылым және технология

✅ Sign-up for a free cluster at: mdb.link/free-8CZs-0it9r4
✅ Get help on our Community Forums: mdb.link/community-8CZs-0it9r4
When modeling your data in MongoDB, schema design patterns are important. Knowing what not to do is equally important. Learn common schema design mistakes in part one of this three-part series, so you don't make those mistakes yourself.
Table of Contents
0:00 - Intro to Anti-Patterns
3:55 - Massive Arrays Anti-Pattern
11:59 - Massive Number of Collections Anti-Pattern
Massive Arrays Anti-Pattern: bit.ly/33i3wgU
Massive Number of Collections Anti-Pattern: bit.ly/3cIgEiy
MongoDB Atlas: bit.ly/3jieJns
MongoDB University Course: M001: MongoDB Basics: bit.ly/3097PJy
MongoDB University Course: M100: MongoDB for SQL Pros: bit.ly/39DpvAv
MongoDB University Course: M121: The MongoDB Aggregation Framework: bit.ly/33g99MR
Subscribe to MongoDB ►►► bit.ly/3bpg1Z1
Connect with MongoDB:
Website: bit.ly/2LjtNBZ
Twitter: bit.ly/3fH87gR
Facebook: bit.ly/3fEaIsd
Linkedin: bit.ly/2SY9w90
Instagram: bit.ly/3bn9bDv
TikTok: bit.ly/3fHoqdJ

Пікірлер: 26

  • @MongoDB
    @MongoDB10 ай бұрын

    ✅ Sign-up for a free cluster at: mdb.link/free-8CZs-0it9r4 ✅ Get help on our Community Forums: mdb.link/community-8CZs-0it9r4

  • @techNutt2
    @techNutt22 жыл бұрын

    I just finished this 3 part series and thanks so much for the guidance and the laughter in your Anti-pattern challenge with all of the Parks and Rec references! This is such a great choice for this teaching.

  • @thatguy6664
    @thatguy6664 Жыл бұрын

    Outstanding!! Your series on MongoDB and Node is also incredible. Among the best tutorials I've ever seen - thank you!

  • @harrisfpv
    @harrisfpv3 жыл бұрын

    That was some high quality content!!! Really happy that I came across that video

  • @batressc
    @batressc2 жыл бұрын

    Excelent content! Thank you so much for this series of videos!

  • @saurabhchauhan232
    @saurabhchauhan2323 жыл бұрын

    This is really nice explanation in short video. However I just recommend showing with realtime project will be really helpful.

  • @Dreacon34
    @Dreacon34 Жыл бұрын

    I am little confused tho. first anti-pattern is massiv arrays…. with an example of a very tiny array only to proceed with the second anti-pattern which are massive collections which solution is to create infinite growing arrays aka massiv arrays of sensor data? i am trying to get into MongoDB and this sounds kinda useless. „don’t make things too big our system just can’t handle it“…..

  • @user-wu5ih1xn7h
    @user-wu5ih1xn7h4 ай бұрын

    Amazing Explanation !

  • @varinderpatwal
    @varinderpatwal2 жыл бұрын

    This is superb I was looking for . Thanks.

  • @surajitbarman
    @surajitbarman3 жыл бұрын

    At 17:01 did you mean the including "day" in the default index and not "hour" because the hour level data is being stored in the readings? This will potentially also keep the readings object bounded to 24.

  • @Cysecsg
    @Cysecsg2 жыл бұрын

    Didn’t knew extended reference pattern is a thing. Been doing data modelling using MongoDB blindly and the biggest dilemma faced is should I embed or not. Even if I applied extended reference, I still have to check if the extended embedded data was part of the update or not in the backend, further complicating the logic behind. So are we going to choose more codes, vs performance cost?

  • @gotqn2103
    @gotqn21033 жыл бұрын

    Good video.

  • @christianangelomsulit3759
    @christianangelomsulit37593 жыл бұрын

    How many is “many”?? If will be using embedded pattern?

  • @audweb5193
    @audweb5193 Жыл бұрын

    thank you!!

  • @dileepkumar-ct2hd
    @dileepkumar-ct2hd3 жыл бұрын

    waiting for part 2

  • @SunehraAGhani
    @SunehraAGhani2 жыл бұрын

    Is embeding documents recommended or linking data with ObjectId and ref If I want to store posts of the user in its doc like: new mongoose.Schema({ email, pass... posts: [postSchema] }); Is it recommended or just adding authorId field like this: authorId: { type: mongoose.Schema.Types.ObjectId, ref: 'user' } is recommended? Any help would be appreciated. 😊

  • @jc_alpha
    @jc_alpha2 жыл бұрын

    14:31 - “Each collection would contain documents that store information about one reading for one sensor” I know I’ve heard it all 😂

  • @codefinity
    @codefinity Жыл бұрын

    5:50. Regarding the 16MB document maximum. I doubt that that would occur as you wouldn't have hundreds of thousands of employees in 1⃣ building, right? Now, given that I may want to frequently see all of the buildings and employees separately, so yeah, probably still need 2 collections.

  • @fabriciobedin1565
    @fabriciobedin15653 жыл бұрын

    Thank you, that helped a lot. I just have a question of your example about river stats. Let's suppose we have millions of objects inside the readings array, isn't it the same anti-pattern you showed in the first example? About massive arrays

  • @harrylau93

    @harrylau93

    3 жыл бұрын

    Wondering the same thing

  • @ropen81

    @ropen81

    2 жыл бұрын

    Not really. In her example she said she's bucketing the information, storing one hour's worth of information per sensor 15:55, so each document will have at most 60 items in the readings array (one reading per minute), and I think that is not considered a massive array... But yes if you had millions of readings then it would be a massive array anti-pattern...

  • @colindante5164
    @colindante5164 Жыл бұрын

    Would it be considered an anti-pattern to store 33,000 documents (11kb/ per document ) in a collection? These are NOT nested documents. Thankyou.

  • @mohamedyoussef8835
    @mohamedyoussef8835 Жыл бұрын

    Awesome video ++++++++++++++++++++ 😃

  • @JeffChentingwei628
    @JeffChentingwei628 Жыл бұрын

    What size is called a "Massive" array?

  • @akailok
    @akailok3 жыл бұрын

    Mam your explaination is good.but it's too much theoritcal. Can you please create a mini project using spring boot and mongodb with customer module,order module,billing module in which you can design a mongodb data modeling. This will practically help millions of people. Thanks mam and you look very cute and sweet.

  • @nayansetty2926

    @nayansetty2926

    2 жыл бұрын

    Lemme know if you come across such videos please, giving examples are the key

Келесі