Class CfnTask
- All Implemented Interfaces:
IConstruct,IDependable,IInspectable,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct
AWS::DataSync::Task.
The AWS::DataSync::Task resource specifies a task. A task is a set of two locations (source and destination) and a set of Options that you use to control the behavior of a task. If you don't specify Options when you create a task, AWS DataSync populates them with service defaults.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.datasync.*;
CfnTask cfnTask = CfnTask.Builder.create(this, "MyCfnTask")
.destinationLocationArn("destinationLocationArn")
.sourceLocationArn("sourceLocationArn")
// the properties below are optional
.cloudWatchLogGroupArn("cloudWatchLogGroupArn")
.excludes(List.of(FilterRuleProperty.builder()
.filterType("filterType")
.value("value")
.build()))
.includes(List.of(FilterRuleProperty.builder()
.filterType("filterType")
.value("value")
.build()))
.name("name")
.options(OptionsProperty.builder()
.atime("atime")
.bytesPerSecond(123)
.gid("gid")
.logLevel("logLevel")
.mtime("mtime")
.objectTags("objectTags")
.overwriteMode("overwriteMode")
.posixPermissions("posixPermissions")
.preserveDeletedFiles("preserveDeletedFiles")
.preserveDevices("preserveDevices")
.securityDescriptorCopyFlags("securityDescriptorCopyFlags")
.taskQueueing("taskQueueing")
.transferMode("transferMode")
.uid("uid")
.verifyMode("verifyMode")
.build())
.schedule(TaskScheduleProperty.builder()
.scheduleExpression("scheduleExpression")
.build())
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnTask.static interfaceSpecifies which files, folders, and objects to include or exclude when transferring files from source to destination.static interfaceRepresents the options that are available to control the behavior of a StartTaskExecution operation.static interfaceSpecifies the schedule you want your task to use for repeated executions.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.amazon.awscdk.core.IConstruct
IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.core.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThe ARNs of the destination elastic network interfaces (ENIs) that were created for your subnet.The ARNs of the source ENIs that were created for your subnet.The status of the task that was described.The ARN of the task.The Amazon Resource Name (ARN) of the Amazon CloudWatch log group that is used to monitor and log events in the task.The Amazon Resource Name (ARN) of an AWS storage resource's location.Specifies a list of filter rules that exclude specific data during your transfer.Specifies a list of filter rules that include specific data during your transfer.getName()The name of a task.Specifies the configuration options for a task.Specifies a schedule used to periodically transfer files from a source to a destination location.The Amazon Resource Name (ARN) of the source location for the task.getTags()Specifies the tags that you want to apply to the Amazon Resource Name (ARN) representing the task.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidsetCloudWatchLogGroupArn(String value) The Amazon Resource Name (ARN) of the Amazon CloudWatch log group that is used to monitor and log events in the task.voidsetDestinationLocationArn(String value) The Amazon Resource Name (ARN) of an AWS storage resource's location.voidsetExcludes(List<Object> value) Specifies a list of filter rules that exclude specific data during your transfer.voidsetExcludes(IResolvable value) Specifies a list of filter rules that exclude specific data during your transfer.voidsetIncludes(List<Object> value) Specifies a list of filter rules that include specific data during your transfer.voidsetIncludes(IResolvable value) Specifies a list of filter rules that include specific data during your transfer.voidThe name of a task.voidsetOptions(IResolvable value) Specifies the configuration options for a task.voidSpecifies the configuration options for a task.voidsetSchedule(IResolvable value) Specifies a schedule used to periodically transfer files from a source to a destination location.voidSpecifies a schedule used to periodically transfer files from a source to a destination location.voidsetSourceLocationArn(String value) The Amazon Resource Name (ARN) of the source location for the task.Methods inherited from class software.amazon.awscdk.core.CfnResource
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, isCfnResource, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.core.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.core.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.amazon.awscdk.core.Construct
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validateMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnTask
protected CfnTask(software.amazon.jsii.JsiiObjectRef objRef) -
CfnTask
protected CfnTask(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnTask
@Stability(Stable) public CfnTask(@NotNull Construct scope, @NotNull String id, @NotNull CfnTaskProps props) Create a newAWS::DataSync::Task.- Parameters:
scope-- scope in which this resource is defined.
id-- scoped id of the resource.
props-- resource properties.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector-- tree inspector to collect and process attributes.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrDestinationNetworkInterfaceArns
The ARNs of the destination elastic network interfaces (ENIs) that were created for your subnet. -
getAttrSourceNetworkInterfaceArns
The ARNs of the source ENIs that were created for your subnet. -
getAttrStatus
The status of the task that was described. -
getAttrTaskArn
The ARN of the task. -
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getTags
Specifies the tags that you want to apply to the Amazon Resource Name (ARN) representing the task.Tags are key-value pairs that help you manage, filter, and search for your DataSync resources.
-
getDestinationLocationArn
The Amazon Resource Name (ARN) of an AWS storage resource's location. -
setDestinationLocationArn
The Amazon Resource Name (ARN) of an AWS storage resource's location. -
getSourceLocationArn
The Amazon Resource Name (ARN) of the source location for the task. -
setSourceLocationArn
The Amazon Resource Name (ARN) of the source location for the task. -
getCloudWatchLogGroupArn
The Amazon Resource Name (ARN) of the Amazon CloudWatch log group that is used to monitor and log events in the task.For more information about how to use CloudWatch Logs with DataSync, see Monitoring Your Task in the AWS DataSync User Guide.
For more information about these groups, see Working with Log Groups and Log Streams in the Amazon CloudWatch Logs User Guide .
-
setCloudWatchLogGroupArn
The Amazon Resource Name (ARN) of the Amazon CloudWatch log group that is used to monitor and log events in the task.For more information about how to use CloudWatch Logs with DataSync, see Monitoring Your Task in the AWS DataSync User Guide.
For more information about these groups, see Working with Log Groups and Log Streams in the Amazon CloudWatch Logs User Guide .
-
getExcludes
Specifies a list of filter rules that exclude specific data during your transfer.For more information and examples, see Filtering data transferred by DataSync .
-
setExcludes
Specifies a list of filter rules that exclude specific data during your transfer.For more information and examples, see Filtering data transferred by DataSync .
-
setExcludes
Specifies a list of filter rules that exclude specific data during your transfer.For more information and examples, see Filtering data transferred by DataSync .
-
getIncludes
Specifies a list of filter rules that include specific data during your transfer.For more information and examples, see Filtering data transferred by DataSync .
-
setIncludes
Specifies a list of filter rules that include specific data during your transfer.For more information and examples, see Filtering data transferred by DataSync .
-
setIncludes
Specifies a list of filter rules that include specific data during your transfer.For more information and examples, see Filtering data transferred by DataSync .
-
getName
The name of a task.This value is a text reference that is used to identify the task in the console.
-
setName
The name of a task.This value is a text reference that is used to identify the task in the console.
-
getOptions
Specifies the configuration options for a task. Some options include preserving file or object metadata and verifying data integrity.You can also override these options before starting an individual run of a task (also known as a task execution ). For more information, see StartTaskExecution .
-
setOptions
Specifies the configuration options for a task. Some options include preserving file or object metadata and verifying data integrity.You can also override these options before starting an individual run of a task (also known as a task execution ). For more information, see StartTaskExecution .
-
setOptions
Specifies the configuration options for a task. Some options include preserving file or object metadata and verifying data integrity.You can also override these options before starting an individual run of a task (also known as a task execution ). For more information, see StartTaskExecution .
-
getSchedule
Specifies a schedule used to periodically transfer files from a source to a destination location.The schedule should be specified in UTC time. For more information, see Scheduling your task .
-
setSchedule
Specifies a schedule used to periodically transfer files from a source to a destination location.The schedule should be specified in UTC time. For more information, see Scheduling your task .
-
setSchedule
Specifies a schedule used to periodically transfer files from a source to a destination location.The schedule should be specified in UTC time. For more information, see Scheduling your task .
-