This function detaches (disconnects) the replica identified by the channel pointer.
MCO_RET mco_HA_detach_replica ( mco_db_h db,
mco_channel_h chan)
| db | Connection handle to master database |
|
chan |
A pointer to the channel descriptor (see |
This function detaches (disconnects) the replica identified by the channel pointer chan. It also performs necessary clean up. On the replica side, will return with mco_nw_attach_master()stop_reason == MCO_HA_REPLICA_MASTER_REQUESTED_DISCONNECT.
| MCO_S_OK | Successful. |
| MCO_E_HA_NOT_INITIALIZED | The HA subsystem has not been initialized – the function mco_HA_start() must be called first. |
| MCO_E_HA_INVCHANNEL | No replica was found with this I/O channel. |
| MCO_E_HA_IOERROR | The master was unable to send the DETACH message to the replica. |