6.9.2. Connector Automatic Reconnect

Version Support: 2.0.2 or later

Automatic reconnect enables the Connector to re-establish a connection in the event of a transient failure. Under specific circumstances, the Connector will also retry the query.

  1. Connector automatic reconnect is enabled by default in Proxy and Smartscale modes. Use the tpm command option --connector-autoreconnect=false to disable automatic reconnect.

  2. This feature is not available while running in Bridge Mode. Use the tpm command option --connector-bridge-mode=false to disable Bridge mode.

  3. Automatic reconnect enables retries of statements under the following circumstances:

    • not in bridge mode

    • not inside a transaction

    • no temp table has been created

    • no lock acquired and not released

    • the request is a read

To disable:

shell> tpm update alpha --connector-autoreconnect=false

The autoreconnect status can be monitored within the autoReconnect parameter output by the tungsten show variables while connected to the Connector. For example:

shell> tpm connector
mysql> tungsten show variables like "autoReconnect";
+----------------------+---------------+-------+
| Variable_Type        | Variable_name | Value |
+----------------------+---------------+-------+
| connector.properties | autoReconnect | false  |
+----------------------+---------------+-------+
1 row in set (0.00 sec)

The above output indicates that the autoreconnect feature is disabled. The tungsten show command is not available in Bridge mode.