The ALIYUN::HBR::OtsBackupPlan resource creates a backup plan for a Tablestore instance.
Syntax
{
"Type": "ALIYUN::HBR::OtsBackupPlan",
"Properties": {
"BackupType": String,
"PlanName": String,
"Retention": Integer,
"Schedule": String,
"VaultId": String,
"CrossAccountUserId": String,
"CrossAccountRoleName": String,
"CrossAccountType": String,
"Disabled": Boolean,
"InstanceName": String,
"OtsDetail": Map,
"Rules": List
}
}
Properties
|
Parameter |
Type |
Required |
Updatable |
Description |
Constraints |
|
BackupType |
String |
Yes |
No |
The backup type. |
Valid value:
|
|
PlanName |
String |
Yes |
Yes |
The name of the backup plan. |
The name must be 1 to 64 characters in length. The backup plan name for each data source type must be unique within a single backup vault. |
|
Retention |
Integer |
Yes |
Yes |
The retention period for backups, in days. |
Minimum value: 1. |
|
Schedule |
String |
Yes |
Yes |
The backup schedule. |
The format is
|
|
VaultId |
String |
Yes |
Yes |
The ID of the backup vault. |
None |
|
CrossAccountRoleName |
String |
No |
No |
The name of the RAM role that is created in the source account for the cross-account backup. |
None |
|
CrossAccountType |
String |
No |
No |
The type of cross-account backup. |
Valid values:
|
|
CrossAccountUserId |
String |
No |
No |
The ID of the source account for the cross-account backup. |
None |
|
Disabled |
Boolean |
No |
No |
Specifies whether to disable the backup plan. |
None |
|
InstanceName |
String |
No |
No |
The name of the Tablestore instance. |
None |
|
OtsDetail |
Map |
No |
Yes |
The details of the Tablestore instance. |
For more information, see OtsDetail properties. |
|
Rules |
List |
No |
Yes |
A list of backup rules. |
Maximum number of rules: 64. For more information, see Rules properties. |
OtsDetail syntax
"OtsDetail": {
"TableNames": List
}
OtsDetail properties
|
Parameter |
Type |
Required |
Updatable |
Description |
Constraints |
|
TableNames |
List |
No |
Yes |
The names of the tables in the Tablestore instance to back up. |
None |
Rules syntax
"Rules": [
{
"Schedule": String,
"BackupType": String,
"Retention": Integer,
"Disabled": Boolean,
"RuleName": String
}
]
Rules properties
|
Parameter |
Type |
Required |
Updatable |
Description |
Constraints |
|
BackupType |
String |
No |
Yes |
The backup type for the rule. |
Valid values:
|
|
Disabled |
Boolean |
No |
Yes |
Specifies whether to disable the rule. |
None |
|
Retention |
Integer |
No |
Yes |
The retention period, in days, for backups created by this rule. |
Minimum value: 1. |
|
RuleName |
String |
No |
Yes |
The name of the rule. |
None |
|
Schedule |
String |
No |
Yes |
The backup schedule for the rule. |
The format is
|
Return values
Fn::GetAtt
PlanId: The ID of the backup plan.
Examples
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
InstanceName:
Type: String
Description:
en: The name of the Tablestore instance.
Required: false
CrossAccountUserId:
Type: String
Description:
en: The ID of the source account for the cross-account backup.
Required: false
CrossAccountRoleName:
Type: String
Description:
en: The name of the RAM role that is created in the source account for the cross-account backup.
Required: false
Schedule:
Type: String
Description:
en: 'The backup schedule, formatted as `I|{startTime}|{interval}`. This specifies a recurring task that starts at `{startTime}` and runs at the specified `{interval}`. Missed tasks are not run retroactively, and a new task will not start until the previous one is complete.'
Required: true
CrossAccountType:
Type: String
Description:
en: 'The type of cross-account backup. Valid values: SELF_ACCOUNT, CROSS_ACCOUNT.'
AllowedValues:
- SELF_ACCOUNT
- CROSS_ACCOUNT
Required: false
BackupType:
Type: String
Description:
en: 'The backup type. Valid value: COMPLETE.'
AllowedValues:
- COMPLETE
Required: true
PlanName:
Type: String
Description:
en: 'The name of the backup plan. The name must be 1 to 64 characters in length. The backup plan name for each data source type must be unique within a single backup vault.'
Required: true
MinLength: 1
MaxLength: 64
VaultId:
Type: String
Description:
en: The ID of the backup vault.
Required: true
Retention:
Type: Number
Description:
en: 'The retention period for backups, in days. Minimum value: 1.'
Required: true
MinValue: 1
Disabled:
Type: Boolean
Description:
en: 'Specifies whether to disable the backup plan. Valid values: true, false.'
Required: false
OtsDetail:
AssociationPropertyMetadata:
Parameters:
TableNames:
AssociationPropertyMetadata:
Parameter:
Type: String
Description:
en: The name of a table in the Tablestore instance to back up.
Required: false
Type: Json
AssociationProperty: List[Parameter]
Description:
en: The names of the tables in the Tablestore instance to back up.
Required: false
Type: Json
Description:
en: The details of the Tablestore instance.
Required: false
Rules:
AssociationPropertyMetadata:
Parameters:
Schedule:
Type: String
Description:
en: 'The backup schedule for the rule, formatted as `I|{startTime}|{interval}`. This specifies a recurring task that starts at `{startTime}` and runs at the specified `{interval}`. Missed tasks are not run retroactively, and a new task will not start until the previous one is complete.'
Required: false
BackupType:
Type: String
Description:
en: 'The backup type for the rule. Valid values: COMPLETE, INCREMENTAL.'
AllowedValues:
- COMPLETE
- INCREMENTAL
Required: false
Retention:
Type: Number
Description:
en: 'The retention period, in days, for backups created by this rule. Minimum value: 1.'
Required: false
MinValue: 1
Disabled:
Type: Boolean
Description:
en: Specifies whether to disable the rule.
Required: false
RuleName:
Type: String
Description:
en: The name of the rule.
Required: false
Type: Json
AssociationProperty: List[Parameters]
Description:
en: A list of backup rules.
Required: false
MaxLength: 64
Resources:
OtsBackupPlan:
Type: ALIYUN::HBR::OtsBackupPlan
Properties:
InstanceName:
Ref: InstanceName
CrossAccountUserId:
Ref: CrossAccountUserId
CrossAccountRoleName:
Ref: CrossAccountRoleName
Schedule:
Ref: Schedule
CrossAccountType:
Ref: CrossAccountType
BackupType:
Ref: BackupType
PlanName:
Ref: PlanName
VaultId:
Ref: VaultId
Retention:
Ref: Retention
Disabled:
Ref: Disabled
OtsDetail:
Ref: OtsDetail
Rules:
Ref: Rules
Outputs:
PlanId:
Description: The ID of the backup plan.
Value:
Fn::GetAtt:
- OtsBackupPlan
- PlanId
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"InstanceName": {
"Type": "String",
"Description": {
"en": "The name of the Tablestore instance."
},
"Required": false
},
"CrossAccountUserId": {
"Type": "String",
"Description": {
"en": "The ID of the source account for the cross-account backup."
},
"Required": false
},
"CrossAccountRoleName": {
"Type": "String",
"Description": {
"en": "The name of the RAM role that is created in the source account for the cross-account backup."
},
"Required": false
},
"Schedule": {
"Type": "String",
"Description": {
"en": "The backup schedule, formatted as `I|{startTime}|{interval}`. This specifies a recurring task that starts at `{startTime}` and runs at the specified `{interval}`. Missed tasks are not run retroactively, and a new task will not start until the previous one is complete."
},
"Required": true
},
"CrossAccountType": {
"Type": "String",
"Description": {
"en": "The type of cross-account backup. Valid values: SELF_ACCOUNT, CROSS_ACCOUNT."
},
"AllowedValues": [
"SELF_ACCOUNT",
"CROSS_ACCOUNT"
],
"Required": false
},
"BackupType": {
"Type": "String",
"Description": {
"en": "The backup type. Valid value: COMPLETE."
},
"AllowedValues": [
"COMPLETE"
],
"Required": true
},
"PlanName": {
"Type": "String",
"Description": {
"en": "The name of the backup plan. The name must be 1 to 64 characters in length. The backup plan name for each data source type must be unique within a single backup vault."
},
"Required": true,
"MinLength": 1,
"MaxLength": 64
},
"VaultId": {
"Type": "String",
"Description": {
"en": "The ID of the backup vault."
},
"Required": true
},
"Retention": {
"Type": "Number",
"Description": {
"en": "The retention period for backups, in days. Minimum value: 1."
},
"Required": true,
"MinValue": 1
},
"Disabled": {
"Type": "Boolean",
"Description": {
"en": "Specifies whether to disable the backup plan. Valid values: true, false."
},
"Required": false
},
"OtsDetail": {
"AssociationPropertyMetadata": {
"Parameters": {
"TableNames": {
"AssociationPropertyMetadata": {
"Parameter": {
"Type": "String",
"Description": {
"en": "The name of a table in the Tablestore instance to back up."
},
"Required": false
}
},
"Type": "Json",
"AssociationProperty": "List[Parameter]",
"Description": {
"en": "The names of the tables in the Tablestore instance to back up."
},
"Required": false
}
}
},
"Type": "Json",
"Description": {
"en": "The details of the Tablestore instance."
},
"Required": false
},
"Rules": {
"AssociationPropertyMetadata": {
"Parameters": {
"Schedule": {
"Type": "String",
"Description": {
"en": "The backup schedule for the rule, formatted as `I|{startTime}|{interval}`. This specifies a recurring task that starts at `{startTime}` and runs at the specified `{interval}`. Missed tasks are not run retroactively, and a new task will not start until the previous one is complete."
},
"Required": false
},
"BackupType": {
"Type": "String",
"Description": {
"en": "The backup type for the rule. Valid values: COMPLETE, INCREMENTAL."
},
"AllowedValues": [
"COMPLETE",
"INCREMENTAL"
],
"Required": false
},
"Retention": {
"Type": "Number",
"Description": {
"en": "The retention period, in days, for backups created by this rule. Minimum value: 1."
},
"Required": false,
"MinValue": 1
},
"Disabled": {
"Type": "Boolean",
"Description": {
"en": "Specifies whether to disable the rule."
},
"Required": false
},
"RuleName": {
"Type": "String",
"Description": {
"en": "The name of the rule."
},
"Required": false
}
}
},
"Type": "Json",
"AssociationProperty": "List[Parameters]",
"Description": {
"en": "A list of backup rules."
},
"Required": false,
"MaxLength": 64
}
},
"Resources": {
"OtsBackupPlan": {
"Type": "ALIYUN::HBR::OtsBackupPlan",
"Properties": {
"InstanceName": {
"Ref": "InstanceName"
},
"CrossAccountUserId": {
"Ref": "CrossAccountUserId"
},
"CrossAccountRoleName": {
"Ref": "CrossAccountRoleName"
},
"Schedule": {
"Ref": "Schedule"
},
"CrossAccountType": {
"Ref": "CrossAccountType"
},
"BackupType": {
"Ref": "BackupType"
},
"PlanName": {
"Ref": "PlanName"
},
"VaultId": {
"Ref": "VaultId"
},
"Retention": {
"Ref": "Retention"
},
"Disabled": {
"Ref": "Disabled"
},
"OtsDetail": {
"Ref": "OtsDetail"
},
"Rules": {
"Ref": "Rules"
}
}
}
},
"Outputs": {
"PlanId": {
"Description": "The ID of the backup plan.",
"Value": {
"Fn::GetAtt": [
"OtsBackupPlan",
"PlanId"
]
}
}
}
}