Draft: ZMySQLDA: support transaction isolation level per connector
Since MariaDB 10.5, innodb_locks_unsafe_for_binlog
option is removed.
Thanks to continuous performance improvements of InnoDB on recent MariaDB versions, the overall performance seems to be similar to 10.4 with innodb_locks_unsafe_for_binlog
. Still, using READ COMMITTED transaction isolation level is better for performance, if using it is safe, like CMFActivity
and possibly so-called data warehouse usage.
So this merge request extends the connection string syntax so that we can specify transaction isolation level per connector.
configuration advice to upgrade from MariaDB 10.4.
The optimizer_use_condition_selectivity controls which statistics can be used by the optimizer when looking for the best query execution plan.
- Use selectivity of predicates as in MariaDB 5.5.
- Use selectivity of all range predicates supported by indexes.
- Use selectivity of all range predicates estimated without histogram.
- Use selectivity of all range predicates estimated with histogram.
- Additionally use selectivity of certain non-range predicates calculated on record sample. From MariaDB 10.4.1, the default is 4. Until MariaDB 10.4.0, the default is 1.
In our case, we have a good plan with optimizer_use_condition_selectivity=1 but have a bad plan with optimizer_use_condition_selectivity=3 or 4.
innodb_flush_method
is deprecated in MariaDB 11.0. If you want direct I/O bypassing kernel cache, you can use the following configuration.
innodb_data_file_write_through = ON
innodb_log_file_write_through = ON
innodb_data_file_buffering = OFF
innodb_log_file_buffering = OFF```
(this MR supercedes !1997)