RDS for MySQL provides many timeout parameters for you to set. This topic describes these parameters in detail.

Parameter Description
connect_timeout This parameter controls the timeout period for waiting for a successful three-way handshake when a connection is established with the server. It is mainly for connection timeout caused by poor network quality. It is recommended that this parameter be increased by significant fluctuations in access to the Internet.
delayed_insert_timeout Specifies the timeout period of the INSERT statement.
innodb_lock_wait_timeout A lock waits for a timeout period. This is different from locks that wait for a transaction (S or X).
innodb_rollback_on_timeout When the transaction timeout exceeds the value of this parameter, the transaction is rolled back. If set to OFF, only the last request of the transaction is rolled back.
interactive_timeout

wait_timeout

The time that mysql waits before closing an interactive or non-interactive connection. It is recommended that you do not need to set too long, otherwise, it will consume the connection resources of the instance.
lock_wait_timeout Specifies the timeout to try to acquire the metadata lock.
net_read_timeout

net_write_timeout

The timeout time for the server to wait for the network packet sent by the client and the network packet sent to the client. These two parameters are valid for the TCP/IP link and are only valid for the thread in the Activity state.
slave_net_timeout The timeout period for the secondary instance to wait for the synchronization from the primary server. If the period ends, the synchronization task is aborted and the secondary instance retries to connect to the primary server.

References

Reconfigure parameters for an RDS MySQL instance