f9c210923d89aeabfc358fdc7b8bd76df8c23ce8
This merge replaces followers subscription code in order to be optimized and perform less queries. This improvement is done in several steps : * mail followers model has new low-level and optimized methods to compute followers to create or update. It uses SQL queries to fetch data in a single request; * mail thread message_subscribe method is rewritten to use this new method. Its API is also simplified and message_subscribe_user is removed to simplify the whole subscription API; * auto subscription is also rewritten. Fetching subtype data about parent / child like project / task is done in a single query that prepares data. It then uses new method to create followers; Various addons are updated because of message_subscribe or auto subscription change. Functionally behavior should stay the same as purpose is to be equivalent in term of functional coverage. Performance counters show this optimized code works well when dealing with large set of followers to subscribe or update. Most tests perform better of a few queries. Most complex ones involving (auto) subscription of several followers perform way better. About 30% of query are saved in the three top tests, aka between 80 and 90 queries with auto subscription of 10 followers. On overall community runbot we have a gain of about 11K queries. As Odoo data has few followers impact on runbot is probably less interesting than impact on real-life use case. Thanks to @rco-odoo for reviewing, and cheers !
…
…
…
…
Odoo
Odoo is a suite of web based open source business apps.
The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, Purchase Management, ...
Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.
Getting started with Odoo
For a standard installation please follow the Setup instructions from the documentation.
Then follow the developer tutorials
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%