Skip to content

VSN-2437/ perf : use light mappers for inspection and report list endpoints

fatima senan a demandé de fusionner feature/VSN-2437 vers develop

Before :

  • The paginated list endpoints (GET /inspections and GET /reports/filtered-reports) were generating hundreds of sequential SQL queries before responding

After :

  • Added mapToLightResponseDto: scalar-only mapper that skips relation loading
    (sections, field answers, files, presigned URLs).
  • getAllInspectionsWithPagination and getFilteredInspections now use this light mapper → 1 SQL query per page instead of N×M.
  • Added toResponseLight: ModelMapper mapping without Hibernate.initialize on the associated inspection's sections/subsections/fieldAnswers.
  • toResponsePage now uses toResponseLight for paginated list responses.
Modification effectuée par fatima senan

Rapports de requête de fusion