Added mysqli support #1647

Merged
merged 3 commits into from Aug 12, 2015

Projects

None yet

3 participants

@laf
Member
laf commented Aug 8, 2015

Ok, so this provides support for mysqli (we default to standard mysql still with this).

$config['db']['extension'] = 'mysqli'; is all that's needed (@f0o would you mind adding this to the config on this ci build).

It doesn't use any new library at the moment but we should look at doing this (needs a lot of work to update queries), for now I've just replicated dbFacile.php into two new files (mysql and mysqli) and updated all the mysql_ calls to use mysqli_.

Works ok in my install from a poller / webui perspective and is actually quite a simple update so should be all good.

mysql_ is deprecated as of PHP 5.5 and dropped in PHP 7, whilst I don't expect that we will get caught out by this it's worth preparing for. It does also mean we could drop in a dbFacile.pgsql.php if someone wanted to so we could support PostgreSQL :)

@laf laf Added mysqli support
4b49c14
@laf laf added the Enhancement label Aug 8, 2015
@laf laf Added some docs, update config.php.default and web installer to use m…
…ysqli by default
880cccf
@f0o
Member
f0o commented Aug 12, 2015

👍
@paulgear can you kick another Scrut test please?

@laf laf Last fix
a8c03ca
@f0o f0o self-assigned this Aug 12, 2015
@f0o f0o merged commit 409b2ef into librenms:master Aug 12, 2015

2 checks passed

Auto-Deploy Build finished.
Details
Scrutinizer 46 new issues
Details
@laf laf deleted the laf:issue-12-new branch Jan 29, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment