6.3.6. Smartscale Routing

6.3.6.1. Enabling SmartScale Routing

To enable SmartScale routing, configure the dataservice using the --connector-smartscale option. The session ID identification should also be specified by using the --connector-smartscale-sessionid option:

shell> tpm configure alpha \
... \
--connector-smartscale=true \
--connector-smartscale-sessionid=DATABASE

In this mode, any client application can open a connection to the connector, and queries will automatically be redirected according to the SQL statement content.

In addition, all users that connect to the database must be granted the REPLICATION CLIENT privilege so that the user can compare the current replicator progress for session information. This can be granted using:

mysql> GRANT REPLICATION CLIENT ON *.* to app_user@'%'

6.3.6.2. Disabling SmartScale Routing

To disable SmartScale routing if it has been previously configured:

shell> tpm configure alpha \
--connector-smartscale=false