Description
You can call this operation to query the backup overview information of a cluster, including the basic cluster information, latest data backup time, log backup offset, log delay, and backup size.
Call description
Prerequisites
You have the Read-only permission on cluster backup and recovery.
You have passed the authentication for the OCP application service.
Request path
GET /api/v2/ob/clusters/{id}/backup/overview
Request parameters
| Parameter | Type | Required | Example value | Description |
|---|---|---|---|---|
| id | Integer | Yes | 1001 | The ID of the cluster for which you want to query the backup overview information. |
Response parameters
| Parameter | Type | Description |
|---|---|---|
| data | Object | The backup overview. |
| successful | Boolean | Indicates whether the request was successful. |
| timestamp | Datetime | The timestamp when the server completed the request. |
| duration | Integer | The time taken by the server to process the request, in milliseconds. |
| status | Integer | An HTTP status code. |
| traceId | String | The trace ID of the request. This trace ID is used for troubleshooting. |
| server | String | The address of the application server that responded to the request. |
Data structure of ClusterBackupInfoDetail
| Parameter | Type | Description |
|---|---|---|
| clusterId | Long | The ID of the cluster. |
| obClusterId | Long | The ID of the OceanBase cluster. |
| clusterName | String | The name of the cluster. |
| obTenantId | Long | The ID of the OceanBase Database tenant. |
| tenantId | Long | The ID of the tenant. |
| tenantName | String | The name of the tenant. |
| obClusterType | String | The type of the cluster. Valid values: PRIMARY and STANDBY. |
| obClusterStatus | String | The status of the cluster. |
| compactionStatus | String | The major compaction status of the cluster. |
| primaryAndStandbyMode | Boolean | Indicates whether the OceanBase cluster was in primary/standby mode. |
| obVersion | String | The version of the OceanBase cluster. |
| obClusterBackupStatus | String | The backup status. Valid values: HAS_BACKUP_STRATEGY and NO_BACKUP_STRATEGY. |
| obBackupAbility | Object | The backup capability. |
| |----backupAbility | String | The backup capability. Valid values: LOGICAL_BACKUP, PHYSICAL_BACKUP, and LOGICAL_AND_PHYSICAL. |
| |----backupMode | String | The backup mode. Valid values: LOGICAL_BACKUP and PHYSICAL_BACKUP. |
| backupDimension | String | The backup dimension. Valid values: CLUSTER and TENANT. |
| backupScheduleStatus | String | The scheduling status of the backup task. Valid values: NONE, NORMAL, PAUSED, WAITING, and ABNORMAL. |
| lastDataBackupTime | Timestamp | The time when the most recent data backup was performed. |
| latestLogBackupCheckpoint | Timestamp | The latest log backup offset. |
| logBackupDelaySeconds | Long | The log backup delay, in seconds. |
| backupSize | Double | The size of the backup. |
| obStorageVolumeUnit | String | The unit for measuring the size of backup data and logs. Valid values: B, KB, MB, GB, TB, and PB. |
Examples
Sample request
Query the backup overview of the cluster with an ID of 1.
GET /api/v2/ob/clusters/1/backup/overview
Sample response
{
"data": {
"backupDimension": "CLUSTER",
"backupScheduleStatus": "NORMAL",
"clusterId": 1000005,
"clusterName": "yc0820_17",
"compactionStatus": "IDLE",
"lastDataBackupTime": "2021-09-16T17:25:02.993+0800",
"latestLogBackupCheckpoint": "2021-09-22T14:49:07.296+0800",
"logBackupDelaySeconds": 98,
"obBackupAbility": {
"backupAbility": "PHYSICAL_BACKUP",
"backupMode": "PHYSICAL_BACKUP",
"obDataBackupSupportAbility": {
"canDoIncrementalBackup": false,
"fullBackupEnabled": true,
"hint": "During a physical backup, you must perform a full backup before you can perform an incremental backup.",
"incrementBackupEnabled": true
}
},
"obClusterBackupStatus": "HAS_BACKUP_STRATEGY",
"obClusterId": 5,
"obClusterStatus": "RUNNING",
"obClusterType": "PRIMARY",
"obVersion": "2.2.77",
"primaryAndStandbyMode": false
},
"duration": 324,
"server": "a83ad33525",
"status": 200,
"successful": true,
"timestamp": "2021-09-22T14:50:46.414+08:00",
"traceId": "52eddd79029d4a24"
}