[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
** Changed in: mahara Status: Fix Committed = Fix Released -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Fix Released Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
** Changed in: mahara Milestone: 1.8rc1 = 1.8.0 -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Fix Committed Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
** Changed in: mahara Status: Confirmed = Fix Committed -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Fix Committed Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
** Tags added: mysql -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Triaged Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
The adodb mysqli driver requires a different PHP library than the adodb mysql driver: mysql uses the original PHP mysql library: http://nz1.php.net/manual/en/book.mysql.php mysqli uses the Mysql Improved library: http://nz1.php.net/manual/en/book.mysqli.php Since it's conceivable some people might have the first one and not the newer one installed on their computer, we should: 1. Keep the old mysql driver around for at least 1 release 2. In config.php, make mysqli refer to the mysqli driver and mysql5 refer to the current driver. 3. Add an admin screen warning suggesting that they change their DB driver from mysql5 to mysqli. I'm also going to change the recommended postgres config name from postgres8 to just postgres. And I will add an undocumented mysql that points to mysqli. Then when we drop support for the mysql5 driver at some point in the future, we can tell people to just set mysql or postgres. -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Triaged Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
https://reviews.mahara.org/2477 -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Confirmed Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
The way I finally decided to implement this is as follows: 1. I changed the preferred dbtype in config-dist.php to postgres or mysql (we already had code that was transforming the postgres8 and mysql5 into other strings to match the ADODB driver, so I figured that if we're doing that, we may as well make the starting point strings be clean and sensible.) The older postgres8 and mysql5 values are still accepted for backwards-compatibility. 2. If you enter mysql as your dbtype, Mahara checks for the presence of mysqli and uses that as your driver if it is present. If not, it uses the older mysql driver. 3. If it falls back to the older mysql driver, it shows you a warning on the admin screen indicating that you're using the older mysql PHP extension and recommends that you install the mysqli PHP extension. This way, everyone who has the mysqli extension gets silently upgraded to it without having to take any action, and those who don't have it can continue to use the site but get a warning recommending them to upgrade. ** Changed in: mahara Status: Triaged = Confirmed ** Changed in: mahara Assignee: (unassigned) = Aaron Wells (u-aaronw) -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Confirmed Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
Testing instructions: Just use the site, in postgres and mysql. Use it intensively. Do a clean install. You can also test the warning messages by uninstalling the PHP mysql and/or mysqli extensions. In Ubuntu, these are both instaled via the same package, php5-mysql, but you can disable mysqli by commenting out the line extension=mysqli.so in /etc/php5/apache2/conf.d/mysqli.ini -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it! https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Confirmed Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp
[Mahara-contributors] [Bug 1187964] Re: Use adodb mysqli instead of mysql
** Tags added: adodb dmllib -- You received this bug notification because you are a member of Mahara Contributors, which is subscribed to Mahara. Matching subscriptions: Subscription for all Mahara Contrib members https://bugs.launchpad.net/bugs/1187964 Title: Use adodb mysqli instead of mysql Status in Mahara ePortfolio: Triaged Bug description: Mahara is currently using the adodb mysql driver for MySQL connections. This is based on an older PHP library which is no longer in active development and lacks certain features, most notably transactions (see for instance https://mahara.org/interaction/forum/topic.php?id=5434 ). We should probably switch to the adodb mysqli driver, which is built on the newer mysqli PHP library and *does* support transactions. There are two ways we could go about this gracefully: 1. When a user supplies the string mysql5 in their config.php file, we could silently interpret this to mean that they want to use the mysqli driver. (We could alternately provide some other way to indicate they want to use the older mysql library if we really want to support it.) 2. OR, we could show the admin a warning message after they upgrade/install, which tells them they should really change the mysql5 in their config.php to mysqli. I support option #1. Given that we only support mysql and postgres, there's no reason we shouldn't abstract away the connection between config.php and the name of the underlying adodb driver. (For that matter, we should probably change the recommended dbtypes from mysql5 and postgres8 to just mysql and postgres). To manage notifications about this bug go to: https://bugs.launchpad.net/mahara/+bug/1187964/+subscriptions ___ Mailing list: https://launchpad.net/~mahara-contributors Post to : mahara-contributors@lists.launchpad.net Unsubscribe : https://launchpad.net/~mahara-contributors More help : https://help.launchpad.net/ListHelp