failover_global_cluster
async
¶
failover_global_cluster(
*,
config_overrides: Optional[AsyncNeptuneClientConfig] = None,
global_cluster_identifier: Optional[GlobalClusterIdentifier] = None,
target_db_cluster_identifier: Optional[String] = None,
allow_data_loss: Optional[BooleanOptional] = None,
switchover: Optional[BooleanOptional] = None,
) -> FailoverGlobalClusterResult
Initiates the failover process for a Neptune global database.
A failover for a Neptune global database promotes one of secondary read-only DB clusters to be the primary DB cluster and demotes the primary DB cluster to being a secondary (read-only) DB cluster. In other words, the role of the current primary DB cluster and the selected target secondary DB cluster are switched. The selected secondary DB cluster assumes full read/write capabilities for the Neptune global database.
This action applies only to Neptune global databases. This action is only intended for use on healthy Neptune global databases with healthy Neptune DB clusters and no region-wide outages, to test disaster recovery scenarios or to reconfigure the global database topology.
Parameters:
-
global_cluster_identifier(Optional[GlobalClusterIdentifier], default:None) –Identifier of the Neptune global database that should be failed over. The identifier is the unique key assigned by the user when the Neptune global database was created. In other words, it's the name of the global database that you want to fail over.
Constraints: Must match the identifier of an existing Neptune global database.
-
target_db_cluster_identifier(Optional[String], default:None) –The Amazon Resource Name (ARN) of the secondary Neptune DB cluster that you want to promote to primary for the global database.
-
allow_data_loss(Optional[BooleanOptional], default:None) –Specifies whether to allow data loss for this global database cluster operation. Allowing data loss triggers a global failover operation.
If you don't specify
AllowDataLoss, the global database cluster operation defaults to a switchover.Constraints: Can't be specified together with the
Switchoverparameter. -
switchover(Optional[BooleanOptional], default:None) –Specifies whether to switch over this global database cluster.
Constraints: Can't be specified together with the
AllowDataLossparameter.
Raises:
-
DBClusterNotFoundFault–DBClusterIdentifier does not refer to an existing DB cluster.
-
GlobalClusterNotFoundFault–The
GlobalClusterIdentifierdoesn't refer to an existing global database cluster. -
InvalidDBClusterStateFault–The DB cluster is not in a valid state.
-
InvalidGlobalClusterStateFault–The global cluster is in an invalid state and can't perform the requested operation.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_neptune/_services/async_neptune.py
3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 | |