[#5556] Enable connection pooling with master/slave support

Made possible via xPDO implementation of feature #4590.

This currently requires manual configuration via $config_options in the primary MODX config file.

Example:

    $config_options = array (
        xPDO::OPT_CONNECTIONS => array(
            array(
                'dsn' => 'mysql:host=127.0.0.1:19571;dbname=revo_replication;charset=utf8',
                'username' => 'user',
                'password' => 'pwd',
                'options' => array(xPDO::OPT_CONN_MUTABLE => false),
                'driverOptions' => array(),
            ),
            array(
                'dsn' => 'mysql:host=127.0.0.1:19572;dbname=revo_replication;charset=utf8',
                'username' => 'user',
                'password' => 'password',
                'options' => array(xPDO::OPT_CONN_MUTABLE => false),
                'driverOptions' => array(),
            ),
        ),
        xPDO::OPT_CONN_MUTABLE => true,
        xPDO::OPT_CONN_INIT => array(xPDO::OPT_CONN_MUTABLE => false)
    );

xPDO::OPT_CONN_INIT defines what kind of connection should be established when modX is instantiated; in the example, xPDO::OPT_CONN_MUTABLE is false which means a read-only connection is established.

Overrides passed to the modX constructor are used to force mutable connections in the manager and connector index.php files (as well as manager/min/index.php); this is to avoid manager integrity issues when getting random connections to various slaves that may not be immediately up-to-date.
[#5556] Enable connection pooling with master/slave support

Made possible via xPDO implementation of feature #4590.

This currently requires manual configuration via $config_options in the primary MODX config file.

Example:

    $config_options = array (
        xPDO::OPT_CONNECTIONS => array(
            array(
                'dsn' => 'mysql:host=127.0.0.1:19571;dbname=revo_replication;charset=utf8',
                'username' => 'user',
                'password' => 'pwd',
                'options' => array(xPDO::OPT_CONN_MUTABLE => false),
                'driverOptions' => array(),
            ),
            array(
                'dsn' => 'mysql:host=127.0.0.1:19572;dbname=revo_replication;charset=utf8',
                'username' => 'user',
                'password' => 'password',
                'options' => array(xPDO::OPT_CONN_MUTABLE => false),
                'driverOptions' => array(),
            ),
        ),
        xPDO::OPT_CONN_MUTABLE => true,
        xPDO::OPT_CONN_INIT => array(xPDO::OPT_CONN_MUTABLE => false)
    );

xPDO::OPT_CONN_INIT defines what kind of connection should be established when modX is instantiated; in the example, xPDO::OPT_CONN_MUTABLE is false which means a read-only connection is established.

Overrides passed to the modX constructor are used to force mutable connections in the manager and connector index.php files (as well as manager/min/index.php); this is to avoid manager integrity issues when getting random connections to various slaves that may not be immediately up-to-date.

Merge branch 'master-slave' into develop

* master-slave:
  [#5556] Enable connection pooling with master/slave support
  [#4590] Allow multiple connections to be defined for master/slave configurations
Merge branch 'develop' into media-sources
Hide dashboard widget if no output is generated
Add missing double dashboard widget css
[#5539] Add back in compress_css/js for allowing toggling of js/css compression in manager
[#4790] Add support for comment tag token, e.g. [[- comments here]]
Merge branch 'develop' into media-sources
More work on abstractions of classes, starting POC of s3 media source
Add initial UI parts for managing media sources
[#5270] Enable container drag 'n drop in Extended Fields tree
Move Content Disposition and Content Type to Settings tab on Quick Create/Update windows
[#4945] Remove weblink content maxlength restriction
Add xPDOObject->getIterator for iterating aggregate and composite relations
Merge remote branch 'xpdo/develop' into develop

* xpdo/develop:
  Add xPDOObject->getIterator for iterating aggregate and composite relations
[#5068] Move token check for new resources below error validation in processor to prevent bogus duplicate resource issue
Add xPDOObject->getIterator for iterating aggregate and composite relations
[#2737] Centralize logic for changing Context of modResource Children
Add editability screen for media sources; add source properties grid
Add create UI for media sources, fix getlist in file media source, other fixes