MXS-1032: Add configurable connector plugin directory
The connector plugin directory can now be controlled with the `connector_plugindir` argument and configuration option. This should allow the connector to use the system plugins if the versions are binary compatible. Replaced calls to mysql_options to mysql_optionsv as the former is deprecated in Connector-C 3.0 and the latter is supported in Connector-C 2.3.
This commit is contained in:
@ -1181,10 +1181,10 @@ mon_connect_to_db(MXS_MONITOR* mon, MXS_MONITOR_SERVERS *database)
|
||||
|
||||
char *dpwd = decrypt_password(passwd);
|
||||
|
||||
mysql_options(database->con, MYSQL_OPT_CONNECT_TIMEOUT, (void *) &mon->connect_timeout);
|
||||
mysql_options(database->con, MYSQL_OPT_READ_TIMEOUT, (void *) &mon->read_timeout);
|
||||
mysql_options(database->con, MYSQL_OPT_WRITE_TIMEOUT, (void *) &mon->write_timeout);
|
||||
|
||||
mysql_optionsv(database->con, MYSQL_OPT_CONNECT_TIMEOUT, (void *) &mon->connect_timeout);
|
||||
mysql_optionsv(database->con, MYSQL_OPT_READ_TIMEOUT, (void *) &mon->read_timeout);
|
||||
mysql_optionsv(database->con, MYSQL_OPT_WRITE_TIMEOUT, (void *) &mon->write_timeout);
|
||||
mysql_optionsv(database->con, MYSQL_PLUGIN_DIR, get_connector_plugindir());
|
||||
time_t start = time(NULL);
|
||||
bool result = (mxs_mysql_real_connect(database->con, database->server, uname, dpwd) != NULL);
|
||||
time_t end = time(NULL);
|
||||
|
Reference in New Issue
Block a user