Open
Description
The driver options array passed in in https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/OCI8/Driver.php#L36 is ignored and options like sessionMode
, persistent
and pooled
are taken from $params.
The adapters in doctrine currently treat $driverOptions
differently:
- Oracle ignores them and intead uses the
$params
array: https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/OCI8/Driver.php#L44 - MySQL (PDO) uses them: https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/PDOMySql/Driver.php#L44
- PgSqL (PDO) uses them: https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/PDOPgSql/Driver.php#L45
- MySQLi uses the options https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/Mysqli/MysqliConnection.php#L62 and ultimately https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/Mysqli/MysqliConnection.php#L214
- Sqlite (PDO) uses them, but removes
userDefinedFunctions
: https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/PDOSqlite/Driver.php#L59 - SQLSrv uses it as the array used for the actual connection: https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/SQLSrv/Driver.php#L44 and oltimately https://github.com/doctrine/dbal/blob/master/lib/Doctrine/DBAL/Driver/SQLSrv/SQLSrvConnection.php#L55
So I think merging the db options with the params array is a good enough solution. It is what we are planning to do as a workaround until we update to latest doctrine: owncloud/core#23938
Opinions?