add endpoint for fetching task markers specifically
The PUT /tasks/box/:left/:bottom/:right/:top endpoint has some unneeded complexity when fetching for task markers. The reason why that endpoint was so complex is because it is also used to fetch task table data. This led to slower performance when fetching markers because paging, ordering, and sorting was applied.
Because that structure is needed for the tables but not for fetching tasks markers, I have created a new endpoint to reduce complexity: PUT /tasks/markers/:left/:bottom/:right/:top .
This new endpoint exports the same task data as the previous endpoint, but doesn't query for the total task count, and also doesn't do any ordering or paging.
21771 task in view with 1001 task limit:
Old endpoint (Time to complete: ~ 1.1s-1.9s ):
New endpoint (Time to complete: ~ 400ms-600ms):
977 task in view with 1001 task limit:
Old endpoint (Time to complete: ~ 450ms-700ms):
New endpoint (Time to complete: ~300ms-550ms):
Times were recorded on the same device at a similar time, and ran multiple times to get an average. There is a small performance increase with the new endpoint when the number of tasks in view is below the limit. A bigger performance increase is noticeable whenever there are significantly more than 1001 tasks(or the limit) as the endpoint no longer needs to query for all the tasks the meet the filter requirements to get the total tssk count.
I'll get this rebased
Quality Gate passed
Issues
1 New issue
0 Accepted issues
Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code
Quality Gate passed
Issues
1 New issue
0 Accepted issues
Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code
(Approved in direct conversation)
