Reference documentation and code samples for the Google Cloud Sql Admin V1 Client class SqlInstancesPromoteReplicaRequest.
Instance promote replica request.
Generated from protobuf message google.cloud.sql.v1.SqlInstancesPromoteReplicaRequest
Namespace
Google \ Cloud \ Sql \ V1
Methods
__construct
Constructor.
Parameters
Name
Description
data
array
Optional. Data for populating the Message object.
↳ instance
string
Cloud SQL read replica instance name.
↳ project
string
ID of the project that contains the read replica.
↳ failover
bool
Set to true to invoke a replica failover to the designated DR replica. As part of replica failover, the promote operation attempts to add the original primary instance as a replica of the promoted DR replica when the original primary instance comes back online. If set to false or not specified, then the original primary instance becomes an independent Cloud SQL primary instance. Only applicable to MySQL.
getInstance
Cloud SQL read replica instance name.
Returns
Type
Description
string
setInstance
Cloud SQL read replica instance name.
Parameter
Name
Description
var
string
Returns
Type
Description
$this
getProject
ID of the project that contains the read replica.
Returns
Type
Description
string
setProject
ID of the project that contains the read replica.
Parameter
Name
Description
var
string
Returns
Type
Description
$this
getFailover
Set to true to invoke a replica failover to the designated DR
replica. As part of replica failover, the promote operation attempts
to add the original primary instance as a replica of the promoted
DR replica when the original primary instance comes back online.
If set to false or not specified, then the original primary
instance becomes an independent Cloud SQL primary instance.
Only applicable to MySQL.
Returns
Type
Description
bool
setFailover
Set to true to invoke a replica failover to the designated DR
replica. As part of replica failover, the promote operation attempts
to add the original primary instance as a replica of the promoted
DR replica when the original primary instance comes back online.
If set to false or not specified, then the original primary
instance becomes an independent Cloud SQL primary instance.
Only applicable to MySQL.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-09 UTC."],[],[],null,["# Google Cloud Sql Admin V1 Client - Class SqlInstancesPromoteReplicaRequest (1.2.6)\n\nVersion latestkeyboard_arrow_down\n\n- [1.2.6 (latest)](/php/docs/reference/cloud-sql-admin/latest/V1.SqlInstancesPromoteReplicaRequest)\n- [1.2.5](/php/docs/reference/cloud-sql-admin/1.2.5/V1.SqlInstancesPromoteReplicaRequest)\n- [1.1.0](/php/docs/reference/cloud-sql-admin/1.1.0/V1.SqlInstancesPromoteReplicaRequest)\n- [1.0.0](/php/docs/reference/cloud-sql-admin/1.0.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.19.0](/php/docs/reference/cloud-sql-admin/0.19.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.18.0](/php/docs/reference/cloud-sql-admin/0.18.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.17.1](/php/docs/reference/cloud-sql-admin/0.17.1/V1.SqlInstancesPromoteReplicaRequest)\n- [0.16.1](/php/docs/reference/cloud-sql-admin/0.16.1/V1.SqlInstancesPromoteReplicaRequest)\n- [0.12.0](/php/docs/reference/cloud-sql-admin/0.12.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.11.0](/php/docs/reference/cloud-sql-admin/0.11.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.10.0](/php/docs/reference/cloud-sql-admin/0.10.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.9.0](/php/docs/reference/cloud-sql-admin/0.9.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.8.0](/php/docs/reference/cloud-sql-admin/0.8.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.7.0](/php/docs/reference/cloud-sql-admin/0.7.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.6.0](/php/docs/reference/cloud-sql-admin/0.6.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.5.0](/php/docs/reference/cloud-sql-admin/0.5.0/V1.SqlInstancesPromoteReplicaRequest)\n- [0.4.1](/php/docs/reference/cloud-sql-admin/0.4.1/V1.SqlInstancesPromoteReplicaRequest)\n- [0.3.1](/php/docs/reference/cloud-sql-admin/0.3.1/V1.SqlInstancesPromoteReplicaRequest)\n- [0.2.12](/php/docs/reference/cloud-sql-admin/0.2.12/V1.SqlInstancesPromoteReplicaRequest) \nReference documentation and code samples for the Google Cloud Sql Admin V1 Client class SqlInstancesPromoteReplicaRequest.\n\nInstance promote replica request.\n\nGenerated from protobuf message `google.cloud.sql.v1.SqlInstancesPromoteReplicaRequest`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ Sql \\\\ V1\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getInstance\n\nCloud SQL read replica instance name.\n\n### setInstance\n\nCloud SQL read replica instance name.\n\n### getProject\n\nID of the project that contains the read replica.\n\n### setProject\n\nID of the project that contains the read replica.\n\n### getFailover\n\nSet to true to invoke a replica failover to the designated DR\nreplica. As part of replica failover, the promote operation attempts\nto add the original primary instance as a replica of the promoted\nDR replica when the original primary instance comes back online.\n\nIf set to false or not specified, then the original primary\ninstance becomes an independent Cloud SQL primary instance.\nOnly applicable to MySQL.\n\n### setFailover\n\nSet to true to invoke a replica failover to the designated DR\nreplica. As part of replica failover, the promote operation attempts\nto add the original primary instance as a replica of the promoted\nDR replica when the original primary instance comes back online.\n\nIf set to false or not specified, then the original primary\ninstance becomes an independent Cloud SQL primary instance.\nOnly applicable to MySQL."]]