Files
odoo_source/addons/survey/models
Victor Piryns (pivi) 41e3b1cdc3 [PERF] survey: add missing indexes
Description:
Adding missing indexes to support most of the searches on survey's
models to avoid seq.scans and non-selective index scans.
Also adding indexes that are inverse to One2many, or dependencies
of compute fields (as those if not indexes will trigger a seq.scan
when the ORM resolves the dependency tree).
If a domain had multiple criteria, only fields with the highest
selectivity were indexed. This shall also reduce the amount of tuples
returned, reducing IO access and cache trashing.

Cardinality:
survey_survey -> X (reference quantity)
survey_question -> 10X
survey_question_answer -> 50X
survey_user_input -> 330X
survey_user_input_line -> 7200X

Reference:
task-3724844

closes odoo/odoo#158136

Signed-off-by: Olivier Dony (odo) <odo@odoo.com>
2024-03-29 12:38:04 +00:00
..
…