️(backend) optimize number of queries on document list view

I realized most of the database queries made when getting a document
list view were to include nested accesses. This detailed information
about accesses in only necessary for the document detail view.

I introduced a specific serializer for the document list view with
less fields. For a list of 20 documents with 5 accesses, we go down
from 3x5x20= 300 queries to just 3 queries.
This commit is contained in:
Samuel Paccoud - DINUM
2024-11-09 10:27:21 +01:00
committed by Anthony LC
parent 797d9442ac
commit 2c915d53f4
6 changed files with 97 additions and 262 deletions

View File

@@ -39,6 +39,7 @@ and this project adheres to
## Changed
- ⚡️(backend) optimize number of queries on document list view #411
- 🚸(backend) improve users similarity search and sort results #391
- ♻️(frontend) simplify stores #402
- ✨(frontend) update $css Box props type to add styled components RuleSet #423