In my game, I allow users to create a level and upload it to my firebase storage. I also get the download link and upload the URL in a firebase database under a LevelsURL node.
I then want to get a random URL from the database, but I am unable to find the best way to do so as all solutions I found suggested getting the entire node of URLs and choosing a random URL on the client-side.
While this solution technically works, I am concerned if I have a large list of user-created levels as potentially I could have hundreds or thousands of levels and I'm unsure about the performance to download a large list of URLs and the amount of data I have will have to download.
Any suggestions on the best approach to get a random file from firebase storage?