[MDEV-15253] Default optimizer setting changes for MariaDB 10.4 Created: 2018-02-08 Updated: 2023-04-18 Resolved: 2018-12-09 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer |
| Fix Version/s: | 10.4.1 |
| Type: | Task | Priority: | Critical |
| Reporter: | Sergei Petrunia | Assignee: | Varun Gupta (Inactive) |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | defaults | ||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Sprint: | 10.4.0-1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Description |
|
The current default settings are:
This means many optimizations are not enabled. During discussion on the optimizer call, figured that we should use defaults like so:
The task is:
cc igor, cvicentiu, sanja, varun_raiko, shagalla |
| Comments |
| Comment by Sergei Petrunia [ 2018-02-08 ] | ||||||||
|
join_cache_level:
| ||||||||
| Comment by Sergei Petrunia [ 2018-02-08 ] | ||||||||
|
optimizer_use_condition_selectivity:
Note that histograms are not collected automatically, so the value of 4 will have the same effect as 3 for those who never collected histograms. | ||||||||
| Comment by Sergei Petrunia [ 2018-02-08 ] | ||||||||
|
TODO: As a second step, should histogram_size default be changed from 0 to 255 ? | ||||||||
| Comment by Daniel Black [ 2018-02-09 ] | ||||||||
|
If optimizer_use_condition_selectivity=4 then it would seem a little odd to keep histogram_size at 0. 255 seems like a good default to cover a broad range of values in a column with little cost if this isn't the case. | ||||||||
| Comment by Varun Gupta (Inactive) [ 2018-02-16 ] | ||||||||
|
Milestone1: Increase the value for join_cache_level from 2 to 4 | ||||||||
| Comment by Daniel Black [ 2018-02-18 ] | ||||||||
|
varun de7a3b23ba66e0946adde0906f1972e80b0e700a had the wrong MDEV ref. | ||||||||
| Comment by Varun Gupta (Inactive) [ 2018-05-30 ] | ||||||||
|
Well we are not going to change the value for join_cache_level. It will still remain to be 2. We are not having any improved performance gains here because there is no cost based approach for hash join and we unconditionally always prefer hash join. | ||||||||
| Comment by Varun Gupta (Inactive) [ 2018-09-17 ] | ||||||||
|
The branch where all the changes is 10.4-selectivity4 | ||||||||
| Comment by Varun Gupta (Inactive) [ 2018-09-17 ] | ||||||||
|
One issue we came across while changing the defaults that ANALYZE on a table would become quite slow , because it will also calculate the EITS at the same time. According to the docs:
| ||||||||
| Comment by Varun Gupta (Inactive) [ 2018-12-09 ] | ||||||||
|
Pushed to 10.4 |