This section explains points to consider when creating applications during cluster operations.
See
Refer to the Cluster Operation Guide for information on cluster operations.
If an application connection switch occurs during cluster operations, explicitly close the connection and then reestablish the connection or reexecute the application.
The table below shows errors that may occur during a switch, and the corresponding action to take.
State | Error information | Action | |
---|---|---|---|
Node failure (server failure) | Failure occurs during access | 57P01 (*2) Empty string (*2) NullReferenceException is generated | After the switch is complete, reestablish the connection, or reexecute the application. |
Accessed during node/system failure | Empty string (*2) | ||
Switch to the standby node (standby server) (*1) | Switched during access | 57P01 (*2) Empty string (*2) NullReferenceException is generated | |
Accessed during switch | Empty string (*2) |
*1: Terms enclosed in () are terms used in database multiplexing mode.
*2: This is the return value of the NpgsqlException attribute Code.
In the application, specify the same IP address as the one that was used when creating GIs or takeover network resources. This will enable the application to be executed if a state transition occurs, simply by reexecuting the application without modification.
See
Refer to "Creating Gls or Takeover Network Resources" in the Cluster Operation Guide for details.