Open tdonohue opened 1 week ago
Related issue: https://github.com/DSpace/DSpace/issues/9316
We've investigated the repeated /thumbnail
and /accessStatus
requests before and concluded that they were due to mis-caching of empty/nonexistent embeds. Could contribute a fix.
@ybnd : If you have a fix in place, that'd be wonderful. I think this is related to https://github.com/DSpace/DSpace/issues/9316 which I see is also assigned to Atmire. So, both might be fixed in one PR.
Assigning to you & moving to "in progress"
Describe the bug
In 7.x and 8.x, when a user searches the system, this makes many calls to the REST API to load all the required information to display on the search page. Currently, it first loads the results, then each facet (one by one), then any thumbnails and "accessStatus" (if enabled). We should be able to decrease the number of calls made on this page.
Here's what it looks like on the sandbox.dspace.org in Chrome DevTools when running a search on "test":
We should be able to minimize the number of calls here by using Projections (
embed
parameter). It may still be necessary to load thumbnails individually though.To Reproduce
Steps to reproduce the behavior:
Expected behavior
Ideally, better usage of projections should allow us to load all this information in fewer REST requests. If additional endpoints need to be added to the REST API to support this behavior, then we should add them.