You can use two connection methods for your applications in HotStandby environments, Basic Connectivity and Transparent Connectivity (TC). With Basic Connectivity, the client connects to each of the HSB servers explicitly. With the Transparent Connectivity, the client enacts only one logical connection that is called the TC Connection.
Both connectivity types are supported in the solidDB® ODBC and JDBC drivers, as well as with SMA servers. The connectivity type is defined within the connect string. With Basic Connectivity, the standard solidDB® connection syntax is used. With Transparent Connectivity, a TC-connection-specific syntax is used.
Basic Connectivity
With Basic Connectivity, the application has to take care of connecting to each server of the HotStandby configuration separately, by using specific server addresses. If a failover happens, the active connection is lost, and the application has to reconnect to the new Primary server.
Transparent Connectivity
With Transparent Connectivity, the application does not have to deal with connecting to any specific server, or to reconnect in the case of a failover. The application maintains a logical connection (handle) called a TC Connection. In simple terms, the Transparent Connectivity relieves the application from taking care of the multiplicity of servers and their addresses.
The connection handle is maintained over failovers and switchovers for as long as there is any server in the PRIMARY ACTIVE, PRIMARY ALONE or STANDALONE state, within the specified set of servers. At failovers and switchovers, the driver performs an internal operation called connection switch. The application is notified about the connection switch, because the application must reconstruct some of the session states (depending on the failure transparency level).
Transparent Connectivity with network-based connection
With network-based connections, the application and the servers can be located on the same or different nodes.
Applications can use the load-balancing functionality to send read-only loads to the Secondary server.
Transparent Connectivity with SMA connection
With SMA, there are two applications, one on each HotStandby node. The application on the primary node uses a SMA connection for reads and writes. The application on the secondary uses a SMA connection to execute reads locally; write transactions from the application on the secondary are executed on the primary server using a network connection.
Server failovers and switchovers are handled in principle the same way as with network-based. However, if the application fails because the SMA server has failed, an application-specific high availability handling is needed.