Uploading 50 small FBX files fails silently for many of them with error 429 (Too Many Requests) in console
Opened this issue · 2 comments
Description
I'm trying to upload a big number (50+) of small FBX files (50 files are just 1.71 MB in total) to a new project via Firefox/Chrome on Windows 10. When dragging the files en masse into the Assets view to upload them I noticed that some create the folder, but don't get any content (not even the FBX file itself).
Waiting didn't help, and there was no error message or any kind of activity. Upon opening the browser console I was greeted with a lot of 429 (Too Many Requests)
messages.
Experiments with several batch sizes and different delays between uploading batches made clear that yes, this is the culprit. When I upload 30 files and wait for a minute between batches, everything works with no console messages; when I upload batches of 30 quickly, or e.g. 50 files at once, only folders are created for some of them and I get 429 (Too Many Requests)
messages in the console.
Steps to Reproduce
- Get many small FBX files, e.g. https://kaylousberg.itch.io/restaurant-bits.
- Open the browser console.
- Try to drag the first 50 FBX files from the
KayKit_Restaurant_Bits_1.0_FREE\Assets\fbx
folder into the Assets view to upload them. - See lots of empty folders created and lots of
POST https://playcanvas.com/api/assets 429 (Too Many Requests)
in the console.
Workaround
Upload in batches of 30. Wait between batches. Cross fingers that you have waited long enough. Watch the console for the dreaded message which would mean that you'll have to find out which of the 30 files didn't upload, delete the empty folders and then upload them again after waiting an unspecified time. Rinse and repeat until all files are uploaded.
There should be a UI to inform user about still currently uploading files and Editor should provide some "queue" mechanics, that would attempt uploading again by itself if it was hit by throttler.