All Products
Search
Document Center

PolarDB:FailoverDBClusterZonal

Last Updated:Jun 10, 2026

Memulai failover zona untuk Kluster PolarDB Basis Data Relasional Cloud-Native, mempromosikan node sekunder menjadi primer.

Coba sekarang

Coba API ini di OpenAPI Explorer tanpa perlu penandatanganan manual. Panggilan yang berhasil akan secara otomatis menghasilkan contoh kode SDK sesuai dengan parameter Anda. Unduh kode tersebut dengan kredensial bawaan yang aman untuk penggunaan lokal.

Test

RAM authorization

Tidak ada otorisasi untuk operasi ini. Jika Anda mengalami masalah saat menjalankan operasi ini, hubungi dukungan teknis.

Sintaks permintaan

POST  HTTP/1.1

Parameter permintaan

Parameter

Type

Required

Description

Example

DBClusterId

string

Yes

ID kluster.

pc-**************

TargetDBNodeId

string

No

ID node yang akan dipromosikan menjadi node primer. Jika Anda tidak menentukan parameter ini, sistem secara otomatis memilih node. Panggil operasi DescribeDBClusters untuk mengkueri informasi node, seperti ID node.

pi-***********

RollBackForDisaster

boolean

No

Apakah akan melakukan failback ke zona primer asli setelah failover. Nilai valid:

  • true: Ya.

  • false: Tidak.

false

ClientToken

string

No

Token klien untuk memastikan idempotensi permintaan. Klien menghasilkan token ini. Token harus unik di seluruh permintaan. Token bersifat case-sensitive dan tidak boleh melebihi 64 karakter ASCII.

6000170000591aed949d0f54a343f1a4233c1e7d1c5******

TargetZoneType

string

No

Tipe failover. Nilai valid:

  • Primary: Failover primer/sekunder dalam zona primer.

  • Standby: Beralih ke kluster penyimpanan hot standby.

Primary

Elemen respons

Element

Type

Description

Example

object

RequestId

string

The request ID.

925B84D9-CA72-432C-95CF-738C22******

Contoh

Respons sukses

JSONformat

{
  "RequestId": "925B84D9-CA72-432C-95CF-738C22******"
}

Kode kesalahan

HTTP status code

Error code

Error message

Description

400 HaStatusNotSupport Current DB instance HA status does not support this operation.
400 InvalidDBNodeId.Malformed The specified parameter DBNodeId is not valid.
400 InvalidDBType.Malformed The Specified DBType is not valid.
400 UnsupportHighFrequenceSwitchOver The instance has switch over too frequent within ten minutes.
400 UnsupportWitchUnhealthyReplication The action is unsupported with unhealthy replication.
403 OperationDenied.DBNodeType The operation is not permitted due to type of node.
403 OperationDenied.ClusterCategory The operation is not permitted due to cluster category.
404 InvalidDBCluster.NotFound The DBClusterId provided does not exist in our records.
404 InvalidDBClusterId.Malformed The specified parameter DBClusterId is not valid.

Lihat Error Codes untuk daftar lengkap.

Catatan rilis

Lihat Release Notes untuk daftar lengkap.