CfnTaskProps

class aws_cdk.aws_datasync.CfnTaskProps(*, destination_location_arn, source_location_arn, cloud_watch_log_group_arn=None, excludes=None, includes=None, name=None, options=None, schedule=None, tags=None)

Bases: object

Properties for defining a CfnTask.

Parameters
  • destination_location_arn (str) – The Amazon Resource Name (ARN) of an AWS storage resource’s location.

  • source_location_arn (str) – The Amazon Resource Name (ARN) of the source location for the task.

  • cloud_watch_log_group_arn (Optional[str]) – 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 .

  • excludes (Union[IResolvable, Sequence[Union[IResolvable, FilterRuleProperty, Dict[str, Any]]], None]) – A list of filter rules that determines which files to exclude from a task. The list should contain a single filter string that consists of the patterns to exclude. The patterns are delimited by “|” (that is, a pipe), for example, "/folder1|/folder2" .

  • includes (Union[IResolvable, Sequence[Union[IResolvable, FilterRuleProperty, Dict[str, Any]]], None]) – A list of filter rules that determines which files to include when running a task. The pattern contains a single filter string that consists of the patterns to include. The patterns are delimited by “|” (that is, a pipe), for example, "/folder1|/folder2" .

  • name (Optional[str]) – The name of a task. This value is a text reference that is used to identify the task in the console.

  • options (Union[IResolvable, OptionsProperty, Dict[str, Any], None]) – The set of configuration options that control the behavior of a single execution of the task that occurs when you call StartTaskExecution . You can configure these options to preserve metadata such as user ID (UID) and group ID (GID), file permissions, data integrity verification, and so on. For each individual task execution, you can override these options by specifying the OverrideOptions before starting the task execution. For more information, see the StartTaskExecution operation.

  • schedule (Union[IResolvable, TaskScheduleProperty, Dict[str, Any], None]) – 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 .

  • tags (Optional[Sequence[Union[CfnTag, Dict[str, Any]]]]) – The key-value pair that represents the tag that you want to add to the resource. The value can be an empty string.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html

ExampleMetadata

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk.aws_datasync as datasync

cfn_task_props = datasync.CfnTaskProps(
    destination_location_arn="destinationLocationArn",
    source_location_arn="sourceLocationArn",

    # the properties below are optional
    cloud_watch_log_group_arn="cloudWatchLogGroupArn",
    excludes=[datasync.CfnTask.FilterRuleProperty(
        filter_type="filterType",
        value="value"
    )],
    includes=[datasync.CfnTask.FilterRuleProperty(
        filter_type="filterType",
        value="value"
    )],
    name="name",
    options=datasync.CfnTask.OptionsProperty(
        atime="atime",
        bytes_per_second=123,
        gid="gid",
        log_level="logLevel",
        mtime="mtime",
        object_tags="objectTags",
        overwrite_mode="overwriteMode",
        posix_permissions="posixPermissions",
        preserve_deleted_files="preserveDeletedFiles",
        preserve_devices="preserveDevices",
        security_descriptor_copy_flags="securityDescriptorCopyFlags",
        task_queueing="taskQueueing",
        transfer_mode="transferMode",
        uid="uid",
        verify_mode="verifyMode"
    ),
    schedule=datasync.CfnTask.TaskScheduleProperty(
        schedule_expression="scheduleExpression"
    ),
    tags=[CfnTag(
        key="key",
        value="value"
    )]
)

Attributes

cloud_watch_log_group_arn

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 .

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-cloudwatchloggrouparn

Return type

Optional[str]

destination_location_arn

The Amazon Resource Name (ARN) of an AWS storage resource’s location.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-destinationlocationarn

Return type

str

excludes

A list of filter rules that determines which files to exclude from a task.

The list should contain a single filter string that consists of the patterns to exclude. The patterns are delimited by “|” (that is, a pipe), for example, "/folder1|/folder2" .

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-excludes

Return type

Union[IResolvable, List[Union[IResolvable, FilterRuleProperty]], None]

includes

A list of filter rules that determines which files to include when running a task.

The pattern contains a single filter string that consists of the patterns to include. The patterns are delimited by “|” (that is, a pipe), for example, "/folder1|/folder2" .

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-includes

Return type

Union[IResolvable, List[Union[IResolvable, FilterRuleProperty]], None]

name

The name of a task.

This value is a text reference that is used to identify the task in the console.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-name

Return type

Optional[str]

options

The set of configuration options that control the behavior of a single execution of the task that occurs when you call StartTaskExecution .

You can configure these options to preserve metadata such as user ID (UID) and group ID (GID), file permissions, data integrity verification, and so on.

For each individual task execution, you can override these options by specifying the OverrideOptions before starting the task execution. For more information, see the StartTaskExecution operation.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-options

Return type

Union[IResolvable, OptionsProperty, None]

schedule

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 .

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-schedule

Return type

Union[IResolvable, TaskScheduleProperty, None]

source_location_arn

The Amazon Resource Name (ARN) of the source location for the task.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-sourcelocationarn

Return type

str

tags

The key-value pair that represents the tag that you want to add to the resource.

The value can be an empty string.

Link

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-datasync-task.html#cfn-datasync-task-tags

Return type

Optional[List[CfnTag]]