3DStreet / 3dstreet

🚲🚶🚌 Web-based 3D visualization of streets using A-Frame
https://3dstreet.app
Other
251 stars 33 forks source link

[block] Separate JSON data from `scene` collection documents in Firestore database #598

Open kfarr opened 9 months ago

kfarr commented 9 months ago

EDIT Tue Dec 5 2023: BLOCKED TASK: do not do this task, with new pagination the speed is much improved. We can revisit this later if needed to squeeze more performance juice.

User story: As a user, even with pagination, it takes a long time to download scenes when exploring in open modal. Issue: Firebase returns all fields for a query; 3DStreet scenes are verbose and many are 100kb+

Instead, I'd prefer to only fetch metadata when exploring scenes, and then download scene data only after I've chosen.

Possible methods: 1) Keep existing scenes collection documents for metadata, and create subcollection such as scene_data >> probably the cleanest option 2) Keep existing scenes collection document for scene data, and create separate collection for metadata browsing such as scene_metadata >> seems messy, will duplicate metadata 3) Store .json in firebase storage >> don't want to do this, would like to continue storing scene data in DB for future mutability

Areas affected:

Migration:

kfarr commented 9 months ago

@rostyslavnahornyi can you review the above and provide feedback when you get a chance? Would like your opinion before assigning the task

rostyslavvnahornyi commented 9 months ago

Hello, @kfarr! Thank you, for providing the plan. I think the first option is the best and I agree that it’s the cleanest one.