Thursday, June 19, 2025
1 change · saas-18.3
Enhancements to existing features
This update improves how the Documents app checks user access rights, reducing unnecessary database work. Opening the Documents app with many files should now be significantly faster, improving responsiveness for users and teams managing large document libraries.
Original PR description
Description ----------- Changes introduced: - Replaced `filtered` linear search with direct `search_fetch` using partner's id in the domain when computing `user_permission` in `_get_permission_without_token` function. This optimizes querying document access permissions. - Implemented batch processing for `_get_permission_without_token` to consolidate documents' access permissions into a single database query. Benchmark --------- `_compute_user_permission` for 1.4k documents for request `search_panel_select_range` (called when opening the Documents app) takes: | Before | After | Speed-up | |--------|-------|----------| | 6.86s | 52ms | 131.9x | Reference --------- task-4873406