Class: AWSCDK::Datasync::CfnTaskProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
datasync/cfn_task_props.rb

Overview

Properties for defining a CfnTask.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(destination_location_arn:, source_location_arn:, cloud_watch_log_group_arn: nil, excludes: nil, includes: nil, manifest_config: nil, name: nil, options: nil, schedule: nil, tags: nil, task_mode: nil, task_report_config: nil) ⇒ CfnTaskProps

Returns a new instance of CfnTaskProps.

Parameters:



21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# File 'datasync/cfn_task_props.rb', line 21

def initialize(destination_location_arn:, source_location_arn:, cloud_watch_log_group_arn: nil, excludes: nil, includes: nil, manifest_config: nil, name: nil, options: nil, schedule: nil, tags: nil, task_mode: nil, task_report_config: nil)
  @destination_location_arn = destination_location_arn
  Jsii::Type.check_type(@destination_location_arn, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoic3RyaW5nIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19kYXRhc3luYy5JTG9jYXRpb25FRlNSZWYifSx7ImZxbiI6ImF3cy1jZGstbGliLmludGVyZmFjZXMuYXdzX2RhdGFzeW5jLklMb2NhdGlvblMzUmVmIn1dfX0=")), "destinationLocationArn")
  @source_location_arn = source_location_arn
  Jsii::Type.check_type(@source_location_arn, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoic3RyaW5nIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19kYXRhc3luYy5JTG9jYXRpb25ORlNSZWYifSx7ImZxbiI6ImF3cy1jZGstbGliLmludGVyZmFjZXMuYXdzX2RhdGFzeW5jLklMb2NhdGlvblMzUmVmIn1dfX0=")), "sourceLocationArn")
  @cloud_watch_log_group_arn = cloud_watch_log_group_arn
  Jsii::Type.check_type(@cloud_watch_log_group_arn, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoic3RyaW5nIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19sb2dzLklMb2dHcm91cFJlZiJ9XX19")), "cloudWatchLogGroupArn") unless @cloud_watch_log_group_arn.nil?
  @excludes = excludes
  Jsii::Type.check_type(@excludes, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZGF0YXN5bmMuQ2ZuVGFzay5GaWx0ZXJSdWxlUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "excludes") unless @excludes.nil?
  @includes = includes
  Jsii::Type.check_type(@includes, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZGF0YXN5bmMuQ2ZuVGFzay5GaWx0ZXJSdWxlUHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "includes") unless @includes.nil?
  @manifest_config = manifest_config.is_a?(Hash) ? ::AWSCDK::Datasync::CfnTask::ManifestConfigProperty.new(**manifest_config.transform_keys(&:to_sym)) : manifest_config
  Jsii::Type.check_type(@manifest_config, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19kYXRhc3luYy5DZm5UYXNrLk1hbmlmZXN0Q29uZmlnUHJvcGVydHkifV19fQ==")), "manifestConfig") unless @manifest_config.nil?
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name") unless @name.nil?
  @options = options.is_a?(Hash) ? ::AWSCDK::Datasync::CfnTask::OptionsProperty.new(**options.transform_keys(&:to_sym)) : options
  Jsii::Type.check_type(@options, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19kYXRhc3luYy5DZm5UYXNrLk9wdGlvbnNQcm9wZXJ0eSJ9XX19")), "options") unless @options.nil?
  @schedule = schedule.is_a?(Hash) ? ::AWSCDK::Datasync::CfnTask::TaskScheduleProperty.new(**schedule.transform_keys(&:to_sym)) : schedule
  Jsii::Type.check_type(@schedule, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19kYXRhc3luYy5DZm5UYXNrLlRhc2tTY2hlZHVsZVByb3BlcnR5In1dfX0=")), "schedule") unless @schedule.nil?
  @tags = tags.is_a?(Array) ? tags.map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : tags
  Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil?
  @task_mode = task_mode
  Jsii::Type.check_type(@task_mode, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "taskMode") unless @task_mode.nil?
  @task_report_config = task_report_config.is_a?(Hash) ? ::AWSCDK::Datasync::CfnTask::TaskReportConfigProperty.new(**task_report_config.transform_keys(&:to_sym)) : task_report_config
  Jsii::Type.check_type(@task_report_config, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19kYXRhc3luYy5DZm5UYXNrLlRhc2tSZXBvcnRDb25maWdQcm9wZXJ0eSJ9XX19")), "taskReportConfig") unless @task_report_config.nil?
end

Instance Attribute Details

#cloud_watch_log_group_arnString, ... (readonly)

Specifies the Amazon Resource Name (ARN) of an Amazon CloudWatch log group for monitoring your task.

For Enhanced mode tasks, you don't need to specify anything. DataSync automatically sends logs to a CloudWatch log group named /aws/datasync .

For more information, see Monitoring data transfers with CloudWatch Logs .



66
67
68
# File 'datasync/cfn_task_props.rb', line 66

def cloud_watch_log_group_arn
  @cloud_watch_log_group_arn
end

#destination_location_arnString, ... (readonly)

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



52
53
54
# File 'datasync/cfn_task_props.rb', line 52

def destination_location_arn
  @destination_location_arn
end

#excludesAWSCDK::IResolvable, ... (readonly)

Specifies exclude filters that define the files, objects, and folders in your source location that you don't want DataSync to transfer.

For more information and examples, see Specifying what DataSync transfers by using filters .



73
74
75
# File 'datasync/cfn_task_props.rb', line 73

def excludes
  @excludes
end

#includesAWSCDK::IResolvable, ... (readonly)

Specifies include filters that define the files, objects, and folders in your source location that you want DataSync to transfer.

For more information and examples, see Specifying what DataSync transfers by using filters .



80
81
82
# File 'datasync/cfn_task_props.rb', line 80

def includes
  @includes
end

#manifest_configAWSCDK::IResolvable, ... (readonly)

The configuration of the manifest that lists the files or objects that you want DataSync to transfer.

For more information, see Specifying what DataSync transfers by using a manifest .



87
88
89
# File 'datasync/cfn_task_props.rb', line 87

def manifest_config
  @manifest_config
end

#nameString? (readonly)

Specifies the name of your task.



92
93
94
# File 'datasync/cfn_task_props.rb', line 92

def name
  @name
end

#optionsAWSCDK::IResolvable, ... (readonly)

Specifies your task's settings, such as preserving file metadata, verifying data integrity, among other options.



97
98
99
# File 'datasync/cfn_task_props.rb', line 97

def options
  @options
end

#scheduleAWSCDK::IResolvable, ... (readonly)

Specifies a schedule for when you want your task to run.

For more information, see Scheduling your task .



104
105
106
# File 'datasync/cfn_task_props.rb', line 104

def schedule
  @schedule
end

#source_location_arnString, ... (readonly)

Specifies the ARN of your transfer's source location.



57
58
59
# File 'datasync/cfn_task_props.rb', line 57

def source_location_arn
  @source_location_arn
end

#tagsArray<AWSCDK::CfnTag>? (readonly)

Specifies the tags that you want to apply to your task.

Tags are key-value pairs that help you manage, filter, and search for your DataSync resources.



111
112
113
# File 'datasync/cfn_task_props.rb', line 111

def tags
  @tags
end

#task_modeString? (readonly)

The task mode that you're using.

For more information, see Choosing a task mode for your data transfer .



118
119
120
# File 'datasync/cfn_task_props.rb', line 118

def task_mode
  @task_mode
end

#task_report_configAWSCDK::IResolvable, ... (readonly)

The configuration of your task report, which provides detailed information about your DataSync transfer.

For more information, see Monitoring your DataSync transfers with task reports .



125
126
127
# File 'datasync/cfn_task_props.rb', line 125

def task_report_config
  @task_report_config
end

Class Method Details

.jsii_propertiesObject



127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
# File 'datasync/cfn_task_props.rb', line 127

def self.jsii_properties
  {
    :destination_location_arn => "destinationLocationArn",
    :source_location_arn => "sourceLocationArn",
    :cloud_watch_log_group_arn => "cloudWatchLogGroupArn",
    :excludes => "excludes",
    :includes => "includes",
    :manifest_config => "manifestConfig",
    :name => "name",
    :options => "options",
    :schedule => "schedule",
    :tags => "tags",
    :task_mode => "taskMode",
    :task_report_config => "taskReportConfig",
  }
end

Instance Method Details

#to_jsiiObject



144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
# File 'datasync/cfn_task_props.rb', line 144

def to_jsii
  result = {}
  result.merge!({
    "destinationLocationArn" => @destination_location_arn,
    "sourceLocationArn" => @source_location_arn,
    "cloudWatchLogGroupArn" => @cloud_watch_log_group_arn,
    "excludes" => @excludes,
    "includes" => @includes,
    "manifestConfig" => @manifest_config,
    "name" => @name,
    "options" => @options,
    "schedule" => @schedule,
    "tags" => @tags,
    "taskMode" => @task_mode,
    "taskReportConfig" => @task_report_config,
  })
  result.compact
end