-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Searching for locations is slow #1300
Comments
mahalakshme
changed the title
Editing a catchment via Admin tab slow
Searching for locations is slow
Aug 14, 2024
1t5j0y
added a commit
to avniproject/avni-server
that referenced
this issue
Aug 30, 2024
Pending:
QA Notes:
|
1t5j0y
added a commit
to avniproject/avni-server
that referenced
this issue
Sep 2, 2024
…nce improvement - removed join to title_lineage_locations_view
We should remove - String getTitleLineage() from the interface LocationProjection. It is going to be misleading. Also remove |
Testing notesFollowing functionality works as expected.
|
1t5j0y
added a commit
to avniproject/avni-server
that referenced
this issue
Sep 23, 2024
…clude titleLineage in response
@1t5j0y does the above fix make DEA search also faster. |
Closed
1t5j0y
added a commit
to avniproject/avni-server
that referenced
this issue
Oct 23, 2024
…clude titleLineage in response (cherry picked from commit 9e1d280)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Issues:
Loading of locations takes more time in all the places. By the time the results display the user loses patience and moves away from the page.
Env: prod, org name: Goonj
In Distribution registration form in DEA,
https://{domain_name}/locations/search/find?title=a&typeId=1396&size=100&page=0 - taking 23 secs in DEA
In Admin tab, on clicking a test catchment the already set locations to display takes a minute
https://{domain_name}/locations/search/findAllById?ids={someLocationId} - took 37 secs - fired to fetch the location name already added
https://{domain_name}/locations/search/find?title=&page=0&size=1000&sort=id%2CDESC - took 1.6 min - fired to show a list of locations
https://{domain_name}/locations/search/find?title=ab&page=0&size=1000&sort=id%2CDESC - took 1.9 min - fired as I typed a location name to show the appropriate search results - to add the location starting with ab to the catchment
AC:
The location search and save should be smooth. So the above API calls should not take more than a second or two.
Root cause:
Joining with
title_lineage_locations_view
Technical solution - suggestions:
title_lineage_locations_view
Reason for priority:
title_lineage_locations_view
.Old: Ignore:
Below might help:
locationProjectionBaseQuery
is the bottleneck. Hence, adding an index on lowest_point_id column might help.Old
locationProjectionBaseQuery
to minimise the number of matching rowsQuestions:
If joining with the view is the problem, then we can add a separate below UI in the locations page, to be able to mention the hierarchy instead of searching across all the hierarchy. This hierarchical on DEA and Admin can get enabled on when the number of locations exceeds a particular no.
The text was updated successfully, but these errors were encountered: