ALIYUN::ClickHouse::EnterpriseDBClusterBackupPolicy

更新时间:
复制为 MD 格式

ALIYUN::ClickHouse::EnterpriseDBClusterBackupPolicy类型用于为指定的ClickHouse企业版集群创建备份策略。

语法

{
  "Type": "ALIYUN::ClickHouse::EnterpriseDBClusterBackupPolicy",
  "Properties": {
    "BackupRetentionPeriod": Integer,
    "DbInstanceId": String,
    "PreferredBackupPeriod": String,
    "PreferredBackupTime": String
  }
}

属性

属性名称

类型

必须

允许更新

描述

约束

BackupRetentionPeriod

Integer

可以保留备份数据的天数。

DbInstanceId

String

集群ID。

PreferredBackupPeriod

String

备份周期,

表示系统定期备份数据的星期几。多个日期用逗号(,)分隔。

PreferredBackupTime

String

执行备份任务的时间窗口。

时间以UTC显示。例如,12:00Z-13:00Z表示备份时间窗口从12:00(UTC)到13:00(UTC)。

返回值

Fn::GetAtt

  • BackupState:备份开关。

  • PreferredBackupPeriod:备份周期。

  • PreferredBackupTime:执行备份任务的时间窗口。

  • BackupRetentionPeriod:可以保留备份数据的天数。

示例

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  PreferredBackupPeriod:
    Type: String
    Description:
      en: The backup cycle, which indicates the day of the week when the system regularly backs up data. Separate multiple dates with commas (,).
      zh: 备份周期,表示系统定期备份数据的星期几。多个日期用逗号(,)分隔。
    Required: true
  PreferredBackupTime:
    Type: String
    Description:
      en: The backup time window within which the backup task is performed. The time is displayed in UTC. For example, 12:00Z-13:00Z indicates that the backup time window ranges from 12:00 (UTC) to 13:00 (UTC).
      zh: 执行备份任务的时间窗口。时间以UTC显示。例如,12:00Z-13:00Z表示备份时间窗口从12:00(UTC)到13:00(UTC)。
    Required: true
  BackupRetentionPeriod:
    Type: Number
    Description:
      en: The number of days for which you can retain the backup data.
      zh: 可以保留备份数据的天数。
    Required: true
  DbInstanceId:
    Type: String
    Description:
      en: The cluster ID.
      zh: 集群ID。
    Required: true
Resources:
  ExtensionResource:
    Type: ALIYUN::ClickHouse::EnterpriseDBClusterBackupPolicy
    Properties:
      PreferredBackupPeriod:
        Ref: PreferredBackupPeriod
      PreferredBackupTime:
        Ref: PreferredBackupTime
      BackupRetentionPeriod:
        Ref: BackupRetentionPeriod
      DbInstanceId:
        Ref: DbInstanceId
Outputs:
  BackupState:
    Description:
      en: Backup switch.
      zh: 备份开关。
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - BackupState
  PreferredBackupPeriod:
    Description:
      en: The backup cycle.
      zh: 备份周期。
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - PreferredBackupPeriod
  PreferredBackupTime:
    Description:
      en: The backup time window within which the backup task is performed.
      zh: 执行备份任务的时间窗口。
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - PreferredBackupTime
  BackupRetentionPeriod:
    Description:
      en: The number of days for which you can retain the backup data.
      zh: 可以保留备份数据的天数。
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - BackupRetentionPeriod
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "PreferredBackupPeriod": {
      "Type": "String",
      "Description": {
        "en": "The backup cycle, which indicates the day of the week when the system regularly backs up data. Separate multiple dates with commas (,).",
        "zh": "备份周期,表示系统定期备份数据的星期几。多个日期用逗号(,)分隔。"
      },
      "Required": true
    },
    "PreferredBackupTime": {
      "Type": "String",
      "Description": {
        "en": "The backup time window within which the backup task is performed. The time is displayed in UTC. For example, 12:00Z-13:00Z indicates that the backup time window ranges from 12:00 (UTC) to 13:00 (UTC).",
        "zh": "执行备份任务的时间窗口。时间以UTC显示。例如,12:00Z-13:00Z表示备份时间窗口从12:00(UTC)到13:00(UTC)。"
      },
      "Required": true
    },
    "BackupRetentionPeriod": {
      "Type": "Number",
      "Description": {
        "en": "The number of days for which you can retain the backup data.",
        "zh": "可以保留备份数据的天数。"
      },
      "Required": true
    },
    "DbInstanceId": {
      "Type": "String",
      "Description": {
        "en": "The cluster ID.",
        "zh": "集群ID。"
      },
      "Required": true
    }
  },
  "Resources": {
    "ExtensionResource": {
      "Type": "ALIYUN::ClickHouse::EnterpriseDBClusterBackupPolicy",
      "Properties": {
        "PreferredBackupPeriod": {
          "Ref": "PreferredBackupPeriod"
        },
        "PreferredBackupTime": {
          "Ref": "PreferredBackupTime"
        },
        "BackupRetentionPeriod": {
          "Ref": "BackupRetentionPeriod"
        },
        "DbInstanceId": {
          "Ref": "DbInstanceId"
        }
      }
    }
  },
  "Outputs": {
    "BackupState": {
      "Description": {
        "en": "Backup switch.",
        "zh": "备份开关。"
      },
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "BackupState"
        ]
      }
    },
    "PreferredBackupPeriod": {
      "Description": {
        "en": "The backup cycle.",
        "zh": "备份周期。"
      },
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "PreferredBackupPeriod"
        ]
      }
    },
    "PreferredBackupTime": {
      "Description": {
        "en": "The backup time window within which the backup task is performed.",
        "zh": "执行备份任务的时间窗口。"
      },
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "PreferredBackupTime"
        ]
      }
    },
    "BackupRetentionPeriod": {
      "Description": {
        "en": "The number of days for which you can retain the backup data.",
        "zh": "可以保留备份数据的天数。"
      },
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "BackupRetentionPeriod"
        ]
      }
    }
  }
}