Parallelize API calls on the frontend #1271
Labels
Complexity: Missing
This ticket needs a complexity (good first issue, small, medium, or large)
Feature: Missing
Milestone: Missing
Role: Missing
size: Missing
When the frontend gets 311 request data from the sever, it breaks the request up into multiple calls, each getting 5000 items currently. By default, the frontend displays data for the past week, which is typically 25-30k 311 requests, meaning that we are making 5 API calls sequentially. This takes around 5-10 seconds for me, running on a local frontend. We can parallelize these calls to make the request data load faster.
See the current implementation here.
To parallelize the calls, we have a couple options.
I'm leaning towards #1 right now since it's simpler, and in most cases, I don't think any given day will have significantly more requests such that it's obviating parallelization.
The text was updated successfully, but these errors were encountered: