First log implementation (75730ee) was creating EventIssue objects, and was rollbacking transaction if it exists
The new one has some benefits :
* always log one line by default in log/error.log, but details must be activated though config (channels `Deadlock-WaitTimeout` and `Deadlock-Found`)
* detailed logs are in a dedicated file (log/deadlock.log) :
- easier for our clients to get and share
- has rotation by default
- looking at the file size is a direct way to know if error happened
- more compliant to industry standards !
* the transaction stays untouched, so that the consumer can do whatever it prefers
* DEFAULT value unquoting is done with preg_replace now (clearer that we want to do a string replacement)
* DEFAULT value unquoting works even if DEFAULT is not the last keyword
* change test datasource for more readability (use double quotes when needed)
* case insensitive SQL data type comparison
* some options have also case differences (example 'int(11) unsigned')
* DEFAULT 'NULL' added by MariaDB on all nullable fields
* default values are always surrounded with single quotes on MariaDB
This is a Combodo implementation of PR #91
This code is a drop in replacement based on an abstract counter based on an abstract keyValue store.
The counter can be
- class based (in this case the counter is initialized on max(id) + 1
- key based (in this case the counter starts at 0)
Important: on both cases the counter is no more kept aligned with the primary key.
This lead to a MySQL8 compatible implementation.
* starting a new transaction will send nothing in the DB (only one global transaction : merge nested transactions)
* same for COMMIT or ROLLBACK if more than 1 transaction is opened
* transactions are kept inside \DBObject::DBInsertNoReload, but they can be disabled using config flag db_core_transactions_enabled=false (true by default, hidden by default)
* check DB charset/collation and do conversion if needed
* same for existing tables
* add both info in fields signatures, so that conversions will be trigerred if needed
SVN:trunk[5444]
* use centralized constants instead of literal values in code
* remove config parameters 'db_character_set' and 'db_collation'
* always fix charset when creating/altering column
* backup : use utf8mb4 only for mysqldump >= 5.5.33 (was introduced in 5.5.3 but only available in 5.5.33 for programs)
SVN:trunk[5443]
* backup : add missing PHPDoc
* backup : use a config object instead of each parameter attribute
* CMDBSource::InitServerAndPort : remove static attribute dependency, change visibility
* setup : generate a config instance to use in backup
* backup : add TLS params if needed to the mysqldump call
SVN:trunk[5375]
* mysql connexion opening : simplify code
* rename DB_SSL_* variables to DB_SSL.*
* fix warnings when new param are not set
* persistent connection (host "p:" prefix) is used for every TLS connection
* add some missing @var
SVN:trunk[5307]
* cron.php : use exit(n°) instead of exit n°, and extract codes to constants
* CMDBSource : new MySQLHasGoneAwayException
* exits cron.php on MySQLHasGoneAwayException
* fix backgroundprocess PHPDoc
* new ProcessException and ProcessFatalException
* new cron.php catch blocks
SVN:trunk[5148]