WIP: Introducing READ-COMMITTED isolation connector
This branch is for MariaDB >= 10.5 that does no longer have innodb_locks_unsafe_for_binlog
.
To achieve a good performance in parallel processing, this branch uses following connections.
-
cmf_activity_sql_connection
: READ-COMMITTED isolation -
erp5_sql_connection
: REPEATABLE-READ isolation -
erp5_sql_read_committed_connection
: [NEW] READ-COMMITTED isolation -
erp5_sql_transactionless_connection
: not using transaction
Basically, new erp5_sql_read_committed_connection
is used for INSERT
/DELETE
/REPLACE
operation. For certain cases for which we are sure that READ-COMMITTED isolation is fine, we can use it for SELECT
operation as well, for example alarm
table.
Also for certain cases for which we don't join with other tables, using the default erp5_sql_connection
connection for everything is easier, for example syncml
table.
Note that both READ-COMMITTED transaction and REPEATABLE-READ transaction start right after the Zope transaction starts, and READ-COMMITTED transaction's result cannot be fetched by REPEATABLE-READ transaction. Some unit tests failed by this reason and simply calling self.commit()
will re-starts both MariaDB transactions.