DbPlan
- Implements: IDbPlan
This class encapsulates and extends the ROS resource type ALIYUN::HBR::DbPlanCreates a database backup plan.
Initializers
import com.aliyun.ros.cdk.hbr.DbPlan;
DbPlan.Builder.create(Construct scope, java.lang.String id, java.lang.Boolean enableResourcePropertyConstraint)
.dbPlanName(java.lang.String)
.dbPlanName(IResolvable)
.hostUuid(java.lang.String)
.hostUuid(IResolvable)
.sourceType(java.lang.String)
.sourceType(IResolvable)
.vaultId(java.lang.String)
.vaultId(IResolvable)
// .continuousPlan(java.lang.String)
// .continuousPlan(IResolvable)
// .cumulativePlan(java.lang.String)
// .cumulativePlan(IResolvable)
// .fullPlan(java.lang.String)
// .fullPlan(IResolvable)
// .incPlan(java.lang.String)
// .incPlan(IResolvable)
// .instanceUuid(java.lang.String)
// .instanceUuid(IResolvable)
// .logPlan(java.lang.String)
// .logPlan(IResolvable)
// .maxRateLimit(java.lang.Number)
// .maxRateLimit(IResolvable)
// .maxRetrySeconds(java.lang.Number)
// .maxRetrySeconds(IResolvable)
// .options(java.lang.String)
// .options(IResolvable)
// .source(IResolvable)
// .source(SourceProperty)
.build();
| Name | Type | Description |
|---|---|---|
scope | com.aliyun.ros.cdk.core.Construct | No description. |
id | java.lang.String | No description. |
enableResourcePropertyConstraint | java.lang.Boolean | No description. |
dbPlanName | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property dbPlanName: Display name of the backup plan. |
hostUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property hostUuid: Uuid of the host of the database instance. |
sourceType | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property sourceType: Database type, allowed value: MYSQL, ORACLE, MSSQL. |
vaultId | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property vaultId: Vault ID to create backup plan, the backup data will be stored to the vault. |
continuousPlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property continuousPlan: Continuous backup plan schedule. |
cumulativePlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property cumulativePlan: Cumulative plan schedule, only for mssql. |
fullPlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property fullPlan: Full backup plan schedule. |
incPlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property incPlan: Incremental backup plan schedule. |
instanceUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property instanceUuid: Uuid of database instance. |
logPlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property logPlan: Log backup plan schedule.More details see FullPlan. |
maxRateLimit | java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable | Property maxRateLimit: Max rate limit for backup job,. |
maxRetrySeconds | java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable | Property maxRetrySeconds: Max retry seconds on network failure. |
options | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Property options: Backup options in json format, different for each type of database. |
source | com.aliyun.ros.cdk.core.IResolvable OR SourceProperty | Property source: Which database instance or database will be backup. |
scopeRequired
- Type: com.aliyun.ros.cdk.core.Construct
idRequired
- Type: java.lang.String
enableResourcePropertyConstraintOptional
- Type: java.lang.Boolean
dbPlanNameRequired
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property dbPlanName: Display name of the backup plan.
hostUuidRequired
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property hostUuid: Uuid of the host of the database instance.
sourceTypeRequired
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property sourceType: Database type, allowed value: MYSQL, ORACLE, MSSQL.
vaultIdRequired
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property vaultId: Vault ID to create backup plan, the backup data will be stored to the vault.
continuousPlanOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property continuousPlan: Continuous backup plan schedule.
Use { "type": "continuous" }.
cumulativePlanOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property cumulativePlan: Cumulative plan schedule, only for mssql.
More details see FullPlan.
fullPlanOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property fullPlan: Full backup plan schedule.
daily: {"type": "daily", "start": "00:00:00", "interval": 3}, weekly {"type":"weekly","start": "03:00:00","days": [1,2,3,4,5],"interval": 1}, days can be 0 - 6, 0 means Sunday, and interval can be 1 - 52.
incPlanOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property incPlan: Incremental backup plan schedule.
Only for mysql and oracle. More details see FullPlan.
instanceUuidOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property instanceUuid: Uuid of database instance.
logPlanOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property logPlan: Log backup plan schedule.More details see FullPlan.
maxRateLimitOptional
- Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable
Property maxRateLimit: Max rate limit for backup job,.
maxRetrySecondsOptional
- Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable
Property maxRetrySeconds: Max retry seconds on network failure.
optionsOptional
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Property options: Backup options in json format, different for each type of database.
For Oracle, use {"channels":4,"compression":"lzop","offline_backup":false,"archivelog_reserve_hours":24,"custom_commands":""}, "channels" means numbers of concurrent theads, "archivelog_reserve_hours" means how long before the archive log will be deleted after backup job completed, other paramters should use the default vaule. For Mysql, use {"channels":4,"compression":"lzop","del_binlog":false}, "del_binlog" means whether the binlog will be deleted after backup completed, only take effect for log or continuous backup. For SQL Server, use {"channels":4,"verify":false,"compression":"lzop","backup_new_databases":false}.
sourceOptional
- Type: com.aliyun.ros.cdk.core.IResolvable OR SourceProperty
Property source: Which database instance or database will be backup.
Methods
| Name | Description |
|---|---|
toString | Returns a string representation of this construct. |
synthesize | Allows this construct to emit artifacts into the cloud assembly during synthesis. |
addCondition | No description. |
addCount | No description. |
addDependency | No description. |
addResourceDesc | No description. |
applyRemovalPolicy | No description. |
fetchCondition | No description. |
fetchDependency | No description. |
fetchResourceDesc | No description. |
getAtt | No description. |
setMetadata | No description. |
toString
public java.lang.String toString()
Returns a string representation of this construct.
synthesize
public void synthesize(ISynthesisSession session)
Allows this construct to emit artifacts into the cloud assembly during synthesis.
This method is usually implemented by framework-level constructs such as Stack and Asset as they participate in synthesizing the cloud assembly.
- Type: com.aliyun.ros.cdk.core.ISynthesisSession
The synthesis session.
addCondition
public void addCondition(RosCondition condition)
- Type: com.aliyun.ros.cdk.core.RosCondition
addCount
public void addCount(java.lang.Number OR IResolvable count)
- Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable
addDependency
public void addDependency(Resource resource)
- Type: com.aliyun.ros.cdk.core.Resource
addResourceDesc
public void addResourceDesc(java.lang.String desc)
- Type: java.lang.String
applyRemovalPolicy
public void applyRemovalPolicy(RemovalPolicy policy)
- Type: com.aliyun.ros.cdk.core.RemovalPolicy
fetchCondition
public RosCondition fetchCondition()
fetchDependency
public java.util.List<java.lang.String> fetchDependency()
fetchResourceDesc
public java.lang.String fetchResourceDesc()
getAtt
public IResolvable getAtt(java.lang.String name)
- Type: java.lang.String
setMetadata
public void setMetadata(java.lang.String key, java.lang.Object value)
- Type: java.lang.String
- Type: java.lang.Object
Static Functions
| Name | Description |
|---|---|
isConstruct | Return whether the given object is a Construct. |
isConstruct
import com.aliyun.ros.cdk.hbr.DbPlan;
DbPlan.isConstruct(java.lang.Object x)
Return whether the given object is a Construct.
- Type: java.lang.Object
Properties
| Name | Type | Description |
|---|---|---|
node | com.aliyun.ros.cdk.core.ConstructNode | The construct tree node associated with this construct. |
env | com.aliyun.ros.cdk.core.IResourceEnvironment | The environment this resource belongs to. |
ref | java.lang.String | No description. |
stack | com.aliyun.ros.cdk.core.Stack | The stack in which this resource is defined. |
resource | com.aliyun.ros.cdk.core.RosResource | No description. |
attrContinuousPlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute ContinuousPlan: Continuous backup plan schedule. |
attrContinuousUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute ContinuousUuid: Uuid of continuous backup plan. |
attrCumulativePlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute CumulativePlan: Cumulative plan schedule, only for mssql. |
attrCumulativeUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute CumulativeUuid: Uuid of cumulative plan. |
attrDbPlanName | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute DbPlanName: Display name of the backup plan. |
attrFullPlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute FullPlan: Full backup plan schedule. |
attrFullUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute FullUuid: Uuid of full backup plan. |
attrHostUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute HostUuid: Uuid of the host of the database instance. |
attrIncPlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute IncPlan: Incremental backup plan schedule. |
attrIncUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute IncUuid: Uuid of the incremental bakcup plan. |
attrInstanceUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute InstanceUuid: Uuid of database instance. |
attrLogPlan | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute LogPlan: Log backup plan schedule.More details see FullPlan. |
attrLogUuid | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute LogUuid: Uuid of the log backup plan. |
attrMaxRateLimit | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute MaxRateLimit: Max rate limit for backup job,. |
attrMaxRetrySeconds | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute MaxRetrySeconds: Max retry seconds on network failure. |
attrOptions | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute Options: Backup options in json format, different for each type of database. |
attrPlanId | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute PlanId: Id of the backup plan. |
attrSourceType | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute SourceType: Database type, allowed value: MYSQL, ORACLE, MSSQL. |
attrTarget | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute Target: Target vault to backup. |
attrVaultId | java.lang.String OR com.aliyun.ros.cdk.core.IResolvable | Attribute VaultId: Vault ID to create backup plan, the backup data will be stored to the vault. |
props | DbPlanProps | No description. |
nodeRequired
public ConstructNode getNode();
- Type: com.aliyun.ros.cdk.core.ConstructNode
The construct tree node associated with this construct.
envRequired
public IResourceEnvironment getEnv();
- Type: com.aliyun.ros.cdk.core.IResourceEnvironment
The environment this resource belongs to.
For resources that are created and managed by the CDK (generally, those created by creating new class instances like Role, Bucket, etc.), this is always the same as the environment of the stack they belong to; however, for imported resources (those obtained from static methods like fromRoleArn, fromBucketName, etc.), that might be different than the stack they were imported into.
refRequired
public java.lang.String getRef();
- Type: java.lang.String
stackRequired
public Stack getStack();
- Type: com.aliyun.ros.cdk.core.Stack
The stack in which this resource is defined.
resourceOptional
public RosResource getResource();
- Type: com.aliyun.ros.cdk.core.RosResource
attrContinuousPlanRequired
public java.lang.Object getAttrContinuousPlan();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute ContinuousPlan: Continuous backup plan schedule.
Use { "type": "continuous" }.
attrContinuousUuidRequired
public java.lang.Object getAttrContinuousUuid();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute ContinuousUuid: Uuid of continuous backup plan.
attrCumulativePlanRequired
public java.lang.Object getAttrCumulativePlan();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute CumulativePlan: Cumulative plan schedule, only for mssql.
More details see FullPlan.
attrCumulativeUuidRequired
public java.lang.Object getAttrCumulativeUuid();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute CumulativeUuid: Uuid of cumulative plan.
attrDbPlanNameRequired
public java.lang.Object getAttrDbPlanName();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute DbPlanName: Display name of the backup plan.
attrFullPlanRequired
public java.lang.Object getAttrFullPlan();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute FullPlan: Full backup plan schedule.
daily: {"type": "daily", "start": "00:00:00", "interval": 3}, weekly {"type":"weekly","start": "03:00:00","days": [1,2,3,4,5],"interval": 1}, days can be 0 - 6, 0 means Sunday, and interval can be 1 - 52.
attrFullUuidRequired
public java.lang.Object getAttrFullUuid();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute FullUuid: Uuid of full backup plan.
attrHostUuidRequired
public java.lang.Object getAttrHostUuid();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute HostUuid: Uuid of the host of the database instance.
attrIncPlanRequired
public java.lang.Object getAttrIncPlan();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute IncPlan: Incremental backup plan schedule.
Only for mysql and oracle. More details see FullPlan.
attrIncUuidRequired
public java.lang.Object getAttrIncUuid();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute IncUuid: Uuid of the incremental bakcup plan.
attrInstanceUuidRequired
public java.lang.Object getAttrInstanceUuid();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute InstanceUuid: Uuid of database instance.
attrLogPlanRequired
public java.lang.Object getAttrLogPlan();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute LogPlan: Log backup plan schedule.More details see FullPlan.
attrLogUuidRequired
public java.lang.Object getAttrLogUuid();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute LogUuid: Uuid of the log backup plan.
attrMaxRateLimitRequired
public java.lang.Object getAttrMaxRateLimit();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute MaxRateLimit: Max rate limit for backup job,.
attrMaxRetrySecondsRequired
public java.lang.Object getAttrMaxRetrySeconds();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute MaxRetrySeconds: Max retry seconds on network failure.
attrOptionsRequired
public java.lang.Object getAttrOptions();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute Options: Backup options in json format, different for each type of database.
For Oracle, use {"channels":4,"compression":"lzop","offline_backup":false,"archivelog_reserve_hours":24,"custom_commands":""}, "channels" means numbers of concurrent theads, "archivelog_reserve_hours" means how long before the archive log will be deleted after backup job completed, other paramters should use the default vaule. For Mysql, use {"channels":4,"compression":"lzop","del_binlog":false}, "del_binlog" means whether the binlog will be deleted after backup completed, only take effect for log or continuous backup. For SQL Server, use {"channels":4,"verify":false,"compression":"lzop","backup_new_databases":false}.
attrPlanIdRequired
public java.lang.Object getAttrPlanId();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute PlanId: Id of the backup plan.
attrSourceTypeRequired
public java.lang.Object getAttrSourceType();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute SourceType: Database type, allowed value: MYSQL, ORACLE, MSSQL.
attrTargetRequired
public java.lang.Object getAttrTarget();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute Target: Target vault to backup.
attrVaultIdRequired
public java.lang.Object getAttrVaultId();
- Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable
Attribute VaultId: Vault ID to create backup plan, the backup data will be stored to the vault.
propsRequired
public DbPlanProps getProps();
- Type: DbPlanProps