Skip to content

RestoreTask

This class encapsulates and extends the ROS resource type ALIYUN::DBS::RestoreTask, which is used to create a restore task.

Initializers

import com.aliyun.ros.cdk.dbs.RestoreTask;
RestoreTask.Builder.create(Construct scope, java.lang.String id, java.lang.Boolean enableResourcePropertyConstraint)
    .backupPlanId(java.lang.String)
    .backupPlanId(IResolvable)
    .destinationEndpointInstanceType(java.lang.String)
    .destinationEndpointInstanceType(IResolvable)
    .restoreTaskName(java.lang.String)
    .restoreTaskName(IResolvable)
//  .backupGatewayId(java.lang.Number)
//  .backupGatewayId(IResolvable)
//  .backupSetId(java.lang.String)
//  .backupSetId(IResolvable)
//  .destinationEndpointDatabaseName(java.lang.String)
//  .destinationEndpointDatabaseName(IResolvable)
//  .destinationEndpointInstanceId(java.lang.String)
//  .destinationEndpointInstanceId(IResolvable)
//  .destinationEndpointIp(java.lang.String)
//  .destinationEndpointIp(IResolvable)
//  .destinationEndpointOracleSid(java.lang.String)
//  .destinationEndpointOracleSid(IResolvable)
//  .destinationEndpointPassword(java.lang.String)
//  .destinationEndpointPassword(IResolvable)
//  .destinationEndpointPort(java.lang.Number)
//  .destinationEndpointPort(IResolvable)
//  .destinationEndpointRegion(java.lang.String)
//  .destinationEndpointRegion(IResolvable)
//  .destinationEndpointUserName(java.lang.String)
//  .destinationEndpointUserName(IResolvable)
//  .duplicateConflict(java.lang.String)
//  .duplicateConflict(IResolvable)
//  .restoreDir(java.lang.String)
//  .restoreDir(IResolvable)
//  .restoreHome(java.lang.String)
//  .restoreHome(IResolvable)
//  .restoreObjects(java.lang.String)
//  .restoreObjects(IResolvable)
//  .restoreTime(java.lang.Number)
//  .restoreTime(IResolvable)
//  .startTask(java.lang.Boolean)
//  .startTask(IResolvable)
    .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.
backupPlanId java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property backupPlanId: The ID of the backup plan.
destinationEndpointInstanceType java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointInstanceType: The location of the database.
restoreTaskName java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property restoreTaskName: The name of the restoration task.
backupGatewayId java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property backupGatewayId: The ID of the backup gateway.
backupSetId java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property backupSetId: The ID of the full backup set used for restoration, which is mutually exclusive to RestoreTime.
destinationEndpointDatabaseName java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointDatabaseName: The name of the RDS database.
destinationEndpointInstanceId java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointInstanceId: The ID of the ApsaraDB RDS instance to query.
destinationEndpointIp java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointIp: The endpoint used to connect to the database.
destinationEndpointOracleSid java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointOracleSid: The SID of the Oracle instance.
destinationEndpointPassword java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointPassword: The password that is used to log on to the RDS instance.
destinationEndpointPort java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointPort: The port that is used to access the database of the primary MySQL server.
destinationEndpointRegion java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointRegion: The region of the database.
destinationEndpointUserName java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property destinationEndpointUserName: The database account.
duplicateConflict java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property duplicateConflict: The handling method for conflicts between objects with the same name.
restoreDir java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property restoreDir: DestinationEndpointInstanceType this parameter is required when agent is specified and the backup schedule is MySQL.
restoreHome java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property restoreHome: Database Program Directory.
restoreObjects java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property restoreObjects: Restore an object.
restoreTime java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property restoreTime: The time when the fault is restored.
startTask java.lang.Boolean OR com.aliyun.ros.cdk.core.IResolvable Property startTask: Start restore task after creating a recovery task.

scopeRequired

  • Type: com.aliyun.ros.cdk.core.Construct

idRequired

  • Type: java.lang.String

enableResourcePropertyConstraintOptional

  • Type: java.lang.Boolean

backupPlanIdRequired

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property backupPlanId: The ID of the backup plan.


destinationEndpointInstanceTypeRequired

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointInstanceType: The location of the database.

Valid values:

  • rds
  • ecs
  • express: a database connected over express connect, VPN Gateway, or smart gateway.
  • agent: The database connected through the backup Gateway
  • dds: apsaradb for MongoDB
  • kvstore
  • polardb
  • drds
  • dg: the database is directly connected through IP Address: Port.

restoreTaskNameRequired

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property restoreTaskName: The name of the restoration task.


backupGatewayIdOptional

  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property backupGatewayId: The ID of the backup gateway.

NoteDestinationEndpointInstanceType if you set this parameter to agent, this parameter is required.


backupSetIdOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property backupSetId: The ID of the full backup set used for restoration, which is mutually exclusive to RestoreTime.


destinationEndpointDatabaseNameOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointDatabaseName: The name of the RDS database.

Note When the database type is PostgreSQL or MongoDB, this parameter is required.


destinationEndpointInstanceIdOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointInstanceId: The ID of the ApsaraDB RDS instance to query.

NoteDestinationEndpointInstanceType if the value is RDS, ECS, DDS, or Express, this parameter is required.


destinationEndpointIpOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointIp: The endpoint used to connect to the database.

NoteDestinationEndpointInstanceType is express, agent, or other. This parameter is required.


destinationEndpointOracleSidOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointOracleSid: The SID of the Oracle instance.

Note This parameter is required if the database type is Oracle.


destinationEndpointPasswordOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointPassword: The password that is used to log on to the RDS instance.

Note You must specify this parameter when the database type is Redis, or the database location is agent and the database type is MSSQL.


destinationEndpointPortOptional

  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointPort: The port that is used to access the database of the primary MySQL server.

NoteDestinationEndpointInstanceType is in the format of express, agent, other, or ECS. This parameter is required.


destinationEndpointRegionOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointRegion: The region of the database.

NoteDestinationEndpointInstanceType for RDS, ECS, DDS, Express, or Agent, this parameter is required.


destinationEndpointUserNameOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property destinationEndpointUserName: The database account.

Note You must specify this parameter when the database type is Redis, or the database location is agent and the database type is MSSQL.


duplicateConflictOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property duplicateConflict: The handling method for conflicts between objects with the same name.

Valid values: failure: The object with the same name fails (default). renamenew: renames an object with the same name.


restoreDirOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property restoreDir: DestinationEndpointInstanceType this parameter is required when agent is specified and the backup schedule is MySQL.


restoreHomeOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property restoreHome: Database Program Directory.


restoreObjectsOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property restoreObjects: Restore an object.

Note For details, see the following RestoreObjects if the database is located in an agent, this parameter is required in other scenarios.


restoreTimeOptional

  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property restoreTime: The time when the fault is restored.

Set the value to 1554560477000.


startTaskOptional

  • Type: java.lang.Boolean OR com.aliyun.ros.cdk.core.IResolvable

Property startTask: Start restore task after creating a recovery task.


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.
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.

sessionRequired

  • Type: com.aliyun.ros.cdk.core.ISynthesisSession

The synthesis session.


addCondition

public void addCondition(RosCondition condition)

conditionRequired

  • Type: com.aliyun.ros.cdk.core.RosCondition

addCount

public void addCount(java.lang.Number OR IResolvable count)

countRequired

  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

addDependency

public void addDependency(Resource resource)

resourceRequired

  • Type: com.aliyun.ros.cdk.core.Resource

addResourceDesc

public void addResourceDesc(java.lang.String desc)

descRequired

  • Type: java.lang.String

applyRemovalPolicy

public void applyRemovalPolicy(RemovalPolicy policy)

policyRequired

  • Type: com.aliyun.ros.cdk.core.RemovalPolicy

getAtt

public IResolvable getAtt(java.lang.String name)

nameRequired

  • Type: java.lang.String

setMetadata

public void setMetadata(java.lang.String key, java.lang.Object value)

keyRequired

  • Type: java.lang.String

valueRequired

  • Type: java.lang.Object

Static Functions

Name Description
isConstruct Return whether the given object is a Construct.

isConstruct

import com.aliyun.ros.cdk.dbs.RestoreTask;
RestoreTask.isConstruct(java.lang.Object x)

Return whether the given object is a Construct.

xRequired

  • Type: java.lang.Object

Properties

Name Type Description
node com.aliyun.ros.cdk.core.ConstructNode The construct tree node associated with this construct.
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.
attrRestoreTaskId com.aliyun.ros.cdk.core.IResolvable Attribute RestoreTaskId: The ID of the restoration task.

nodeRequired

public ConstructNode getNode();
  • Type: com.aliyun.ros.cdk.core.ConstructNode

The construct tree node associated with this construct.


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

attrRestoreTaskIdRequired

public IResolvable getAttrRestoreTaskId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute RestoreTaskId: The ID of the restoration task.