diff options
| author | Denis Ledoux <dle@odoo.com> | 2018-12-19 18:45:34 +0100 |
|---|---|---|
| committer | Denis Ledoux <dle@odoo.com> | 2018-12-19 18:49:14 +0100 |
| commit | 5856dab38026524d7f28fd1b1adf2a8c0b3e3015 (patch) | |
| tree | 05eb5133180127375122c763040f5a3ae30af1ac /addons/base_import_module/tests/test_module/static/src | |
| parent | 12df3c6a98e4a925a8aa2e1232497a01cb4f8d69 (diff) | |
[IMP] product: name_get, use mapped to gain some memory
This revision is related to
12df3c6a98e4a925a8aa2e1232497a01cb4f8d69
The above revision serve its purpose as well,
but by avoiding to store the result in a variable,
and using the records cache instead,
we gain some memory, which is noticeable
when there are hundred of thousands products.
The sudo() is important, as it must be the
same environment then the above call to read
to use the same cache.
Otherwise the values won't be in the cache
of self (without sudo),
and it will go get it and prefetch other fields
in the database.
Diffstat (limited to 'addons/base_import_module/tests/test_module/static/src')
0 files changed, 0 insertions, 0 deletions
