Hi Team. Looking for some help on how to model pinot schema. My data model is somewhat similar to Folders & Permissions.i.e. I have Folders entity ( which has metadata) and each folder has users who can access them. Now for my dashboard needs, I will always aggregate on folder metadata but for the current user. I have atleast 100M of folders with each folder having ~100 users who can access them.
I could think of following options,
1) Have a single table with userid, folderid and folder metadata. So each folder id and metadata will be duplicated ~100 times.
2) Have a single table Folder with one column userid that is a json array. Use jsonindex on this userId column.
3) Have 2 tables Folder (with metadata) and another FolderUser mapping that has FolderId,UserId. Use inner join for querying.
Appreciate any help on this. Thanks.