VSN-2437/ perf : use light mappers for inspection and report list endpoints
Before :
- The paginated list endpoints (
GET /inspectionsandGET /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). -
getAllInspectionsWithPaginationandgetFilteredInspectionsnow use this light mapper → 1 SQL query per page instead of N×M. - Added
toResponseLight: ModelMapper mapping withoutHibernate.initializeon the associated inspection's sections/subsections/fieldAnswers. -
toResponsePagenow usestoResponseLightfor paginated list responses.