Note: This page is obsolete. The information is old, outdated, or otherwise currently incorrect. We are keeping the page for historical reasons only. Do not rely on the information in this article.
If case you didn't know:
Features that were in 6.0 and that we can rescue from there and provide value for the users:
note: unless said otherwise, by MRR we mean MRR and ICP, everywhere
There are also unfinished tasks, in various degrees of public availability and readyness:
Some (but not all) of the following might be needed to make a well-rounded release:
The following is the "Igor's list":
1. MRR/ICP --------------- WL#2474: Batched range read handler functions WL#2475: Batched range read functions for MyISAM/InnoDB 2. BKA --------- WL #2771: Usage of multi_read_range in nested loop join 3. Metadata integrity ------------------------- WL #4284 (bug #989): Transactional DDL locking WL#4165: Prepared statements: validation WL#4166: Prepared statements: automatic re-prepare 4. Subqueries ----------------- 4.1 Materialization of non-correlated IN subqueries ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ WL #1110: Materialization WL #4614: Materialization: avoid double subquery materialization WL #4690: Insideout order for materialized non-semijoin subqueries at top-level of the WHERE 4.2. Semi-joins ~~~~~~~~~~~ WL #3740: Subquery optimization: Semijoin: Pull-out of inner tables WL #3741: Subquery optimization: Semijoin: Duplicate elimination strategy WL #3750: Subquery optimization: Semijoin: Duplicate elimination strategy WL #3751: Subquery optimization: Semijoin: Inside-out strategy 4.3. Smart choice between materialization and semi-join ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ WL #3985: Subquery optimization: smart choice between semi-join and materialization 4.4. Derived tables ~~~~~~~~~~~~~~ WL #3485: Subquery optimization: FROM (SELECT) 4.5. EXISTs convertible to IN ~~~~~~~~~~~~~~~~~~~~~~ WL #4389: Make IN optimizations also handle EXISTS 4.6. Materialization for non-correlated NOT IN subqueries ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ WL #3830: Materialization: Partial matching of tuples with NULL components 4.7. Direct evaluation of subqueries with caching ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ WL #3341: Shortcut the evaluation as soon as there is a match WL #1117: Avoid recalculating subquery if external fields have not changed
MySQL Worklog #4614 and MySQL Worklog #4690 are considered droppable.
It seems to be infeasible to take mysql-6.0 and fix it until it has release quality. We'll have to do it other way around: start from mariadb-5.2 codebase and pull features to there, one by one. This process will be called "backport".
MRR/BKA has been there for longer time than other features and so is more stable and so is a natural candidate for the first step.
Needed actions:
After MRR has been pushed, it received a number of code cleanups, bugfixes, and interface adjustments (motivated by BKA and NDB/Falcon implementations). This means that there is no single MRR patch, instead one should go through revisions and cherry-pick MRR-related patches (one of the ways to narrow down the number of revisions: most (all?) MRR fixes were made by [email protected],
with exception of this fix:
2726 Guilhem Bichot 2009-03-13
Fix for multiple symptoms sharing the same cause:
BUG#42297 Maria: crash in multi-range-read code
BUG#42298 Maria: SELECT with join returns no rows
...
In addition to backport, we need the following adjustments:
All of the above is filed as MWL#67: http://askmonty.org/worklog/Server-Sprint/index.pl?tid=67
After the above is done, BKA will work in MariaDB 5.2 codebase in the same way as it worked in MySQL 6.0, but without MRR/InnoDB bugs.
Implement http://askmonty.org/worklog/Server-Sprint/index.pl?tid=68
Implement this item
According to Igor:
Within this milestone, assume a certain join_cache_level setting (it is likely the estimates will be so rough that it won't matter)
TODO: clarify if this includes making the choice between doing MRR scan and then filesorting vs doing non-MRR scan but not having to sort.
After the above is done, we'll have MRR/BKA with cost-based optimization.
This step includes backporting all pushed 6.0's subquery optimizations and fixing open wrong-result or crash bugs, including addressing of these problems:
At the moment it seems the preferred course of action is to first fix the bugs and then backport.
After the above is done, we'll be able to assume that we "got on track" with subquery development and will be able to proceed further in many directions.
NOTE: it is not fully known what we'll discover when this milestone is reacheed. Perhaps, we'll discover that subquery cost model needs some adjustments (but there's always a way out, penalize all non-5.1 plans so that the 5.1 plan wins in near competitions and thus there are no regressions).
After the semi-join subqueries are done, the biggest and most annoying gap in subquery optimizations will be poor FROM subquery handling. Thus, the next item is to take the available code for
and finish that.
(is there really sense to have a linear plan that extends further than this? Let's reach this point and release?)
This is a step that has high ROI, can be done more-or-less indepdendently of the other work, and doesn't require in-depth knowlege of new subquery code/features:
this can be passed over to somebody who haven't worked with subquery code before.
(note: this task has a natural extension: create and use a cache of external_field_values->subquery_result mappings.
Btw, certain nose-trunk databases do not seem to handle this case.
Another separate, high-ROI item:
(TODO check if that's really that WL entry).
(note: after "More subqueries #1/#2 we'll also need MySQL Worklog #3830 before we could count non-WHERE clause subqueries as covered).
Backport the following:
WL #2771: Usage of multi_read_range in nested loop join 3. Metadata integrity ------------------------- WL #4284 (bug #989): Transactional DDL locking WL#4165: Prepared statements: validation WL#4166: Prepared statements: automatic re-prepare
© 2023 MariaDB
Licensed under the Creative Commons Attribution 3.0 Unported License and the GNU Free Documentation License.
https://mariadb.com/kb/en/mariadb-feature-backport/