I am not sure if more than 100 users is allowed now or not but definitely you must have dedicated clusters if you need limitations increase otherwise those tiers are limited by design and there is nothing that can be done…
Having this amount of databases and collections is just not scalable and unadvised for any app design
Customers use this mobile app to view their information, so I created a database for each one. What would be the recommended design? A single database and all collections separated by permission?
So instead of having, for example, 100 databases each with 3 collections, giving a total of 300 collections, would I just have 1 database with 3 collections and store everything there?
The difference would be that in each document I would have an owner_id field that would identify its owner by the user id?
Cool … For each user I have a database, in each one I have 3 collections (customers, products and sales). I will then save ALL documents from ALL users in each of the collections, tagging each document with its unique user ID.
But there’s a problem… For example, let’s say the sales collection has 1,000,000 documents from 100 different users. So user A (who has only 2000 documents) performs a search, won’t he be slowed down by other people’s documents (998,000)?
I don’t know what it’s like in MongoDB in this case, but in traditional databases (MySQL, SQL, etc) it would be slow.
I understand. But in my collection, each document belongs to a GROUP of registered users with email / password and not just one user.
So what I did was this, I put in each document an entire field called groupID and associated it with the groupID field I created for each user in the custom data. For example, user1 and user2 have groupID 1. User3 and user4 have groupID2 and so on.
The groupID is working correctly as an integer. If I put it as ObjectID, would it be better? I tried to test it, but I couldn’t generate a field with this type via NodeJS.