1 /**
2  * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  * SPDX-License-Identifier: Apache-2.0.
4  */
5 
6 #pragma once
7 #include <aws/batch/Batch_EXPORTS.h>
8 #include <aws/batch/BatchRequest.h>
9 #include <aws/core/utils/memory/stl/AWSString.h>
10 #include <aws/batch/model/JobDefinitionType.h>
11 #include <aws/core/utils/memory/stl/AWSMap.h>
12 #include <aws/batch/model/ContainerProperties.h>
13 #include <aws/batch/model/NodeProperties.h>
14 #include <aws/batch/model/RetryStrategy.h>
15 #include <aws/batch/model/JobTimeout.h>
16 #include <aws/core/utils/memory/stl/AWSVector.h>
17 #include <aws/batch/model/PlatformCapability.h>
18 #include <utility>
19 
20 namespace Aws
21 {
22 namespace Batch
23 {
24 namespace Model
25 {
26 
27   /**
28    * <p>Contains the parameters for <code>RegisterJobDefinition</code>.</p><p><h3>See
29    * Also:</h3>   <a
30    * href="http://docs.aws.amazon.com/goto/WebAPI/batch-2016-08-10/RegisterJobDefinitionRequest">AWS
31    * API Reference</a></p>
32    */
33   class AWS_BATCH_API RegisterJobDefinitionRequest : public BatchRequest
34   {
35   public:
36     RegisterJobDefinitionRequest();
37 
38     // Service request name is the Operation name which will send this request out,
39     // each operation should has unique request name, so that we can get operation's name from this request.
40     // Note: this is not true for response, multiple operations may have the same response name,
41     // so we can not get operation's name from response.
GetServiceRequestName()42     inline virtual const char* GetServiceRequestName() const override { return "RegisterJobDefinition"; }
43 
44     Aws::String SerializePayload() const override;
45 
46 
47     /**
48      * <p>The name of the job definition to register. Up to 128 letters (uppercase and
49      * lowercase), numbers, hyphens, and underscores are allowed.</p>
50      */
GetJobDefinitionName()51     inline const Aws::String& GetJobDefinitionName() const{ return m_jobDefinitionName; }
52 
53     /**
54      * <p>The name of the job definition to register. Up to 128 letters (uppercase and
55      * lowercase), numbers, hyphens, and underscores are allowed.</p>
56      */
JobDefinitionNameHasBeenSet()57     inline bool JobDefinitionNameHasBeenSet() const { return m_jobDefinitionNameHasBeenSet; }
58 
59     /**
60      * <p>The name of the job definition to register. Up to 128 letters (uppercase and
61      * lowercase), numbers, hyphens, and underscores are allowed.</p>
62      */
SetJobDefinitionName(const Aws::String & value)63     inline void SetJobDefinitionName(const Aws::String& value) { m_jobDefinitionNameHasBeenSet = true; m_jobDefinitionName = value; }
64 
65     /**
66      * <p>The name of the job definition to register. Up to 128 letters (uppercase and
67      * lowercase), numbers, hyphens, and underscores are allowed.</p>
68      */
SetJobDefinitionName(Aws::String && value)69     inline void SetJobDefinitionName(Aws::String&& value) { m_jobDefinitionNameHasBeenSet = true; m_jobDefinitionName = std::move(value); }
70 
71     /**
72      * <p>The name of the job definition to register. Up to 128 letters (uppercase and
73      * lowercase), numbers, hyphens, and underscores are allowed.</p>
74      */
SetJobDefinitionName(const char * value)75     inline void SetJobDefinitionName(const char* value) { m_jobDefinitionNameHasBeenSet = true; m_jobDefinitionName.assign(value); }
76 
77     /**
78      * <p>The name of the job definition to register. Up to 128 letters (uppercase and
79      * lowercase), numbers, hyphens, and underscores are allowed.</p>
80      */
WithJobDefinitionName(const Aws::String & value)81     inline RegisterJobDefinitionRequest& WithJobDefinitionName(const Aws::String& value) { SetJobDefinitionName(value); return *this;}
82 
83     /**
84      * <p>The name of the job definition to register. Up to 128 letters (uppercase and
85      * lowercase), numbers, hyphens, and underscores are allowed.</p>
86      */
WithJobDefinitionName(Aws::String && value)87     inline RegisterJobDefinitionRequest& WithJobDefinitionName(Aws::String&& value) { SetJobDefinitionName(std::move(value)); return *this;}
88 
89     /**
90      * <p>The name of the job definition to register. Up to 128 letters (uppercase and
91      * lowercase), numbers, hyphens, and underscores are allowed.</p>
92      */
WithJobDefinitionName(const char * value)93     inline RegisterJobDefinitionRequest& WithJobDefinitionName(const char* value) { SetJobDefinitionName(value); return *this;}
94 
95 
96     /**
97      * <p>The type of job definition. For more information about multi-node parallel
98      * jobs, see <a
99      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-job-def.html">Creating
100      * a multi-node parallel job definition</a> in the <i>Batch User Guide</i>.</p>
101      *  <p>If the job is run on Fargate resources, then <code>multinode</code>
102      * isn't supported.</p>
103      */
GetType()104     inline const JobDefinitionType& GetType() const{ return m_type; }
105 
106     /**
107      * <p>The type of job definition. For more information about multi-node parallel
108      * jobs, see <a
109      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-job-def.html">Creating
110      * a multi-node parallel job definition</a> in the <i>Batch User Guide</i>.</p>
111      *  <p>If the job is run on Fargate resources, then <code>multinode</code>
112      * isn't supported.</p>
113      */
TypeHasBeenSet()114     inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; }
115 
116     /**
117      * <p>The type of job definition. For more information about multi-node parallel
118      * jobs, see <a
119      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-job-def.html">Creating
120      * a multi-node parallel job definition</a> in the <i>Batch User Guide</i>.</p>
121      *  <p>If the job is run on Fargate resources, then <code>multinode</code>
122      * isn't supported.</p>
123      */
SetType(const JobDefinitionType & value)124     inline void SetType(const JobDefinitionType& value) { m_typeHasBeenSet = true; m_type = value; }
125 
126     /**
127      * <p>The type of job definition. For more information about multi-node parallel
128      * jobs, see <a
129      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-job-def.html">Creating
130      * a multi-node parallel job definition</a> in the <i>Batch User Guide</i>.</p>
131      *  <p>If the job is run on Fargate resources, then <code>multinode</code>
132      * isn't supported.</p>
133      */
SetType(JobDefinitionType && value)134     inline void SetType(JobDefinitionType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); }
135 
136     /**
137      * <p>The type of job definition. For more information about multi-node parallel
138      * jobs, see <a
139      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-job-def.html">Creating
140      * a multi-node parallel job definition</a> in the <i>Batch User Guide</i>.</p>
141      *  <p>If the job is run on Fargate resources, then <code>multinode</code>
142      * isn't supported.</p>
143      */
WithType(const JobDefinitionType & value)144     inline RegisterJobDefinitionRequest& WithType(const JobDefinitionType& value) { SetType(value); return *this;}
145 
146     /**
147      * <p>The type of job definition. For more information about multi-node parallel
148      * jobs, see <a
149      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-job-def.html">Creating
150      * a multi-node parallel job definition</a> in the <i>Batch User Guide</i>.</p>
151      *  <p>If the job is run on Fargate resources, then <code>multinode</code>
152      * isn't supported.</p>
153      */
WithType(JobDefinitionType && value)154     inline RegisterJobDefinitionRequest& WithType(JobDefinitionType&& value) { SetType(std::move(value)); return *this;}
155 
156 
157     /**
158      * <p>Default parameter substitution placeholders to set in the job definition.
159      * Parameters are specified as a key-value pair mapping. Parameters in a
160      * <code>SubmitJob</code> request override any corresponding parameter defaults
161      * from the job definition.</p>
162      */
GetParameters()163     inline const Aws::Map<Aws::String, Aws::String>& GetParameters() const{ return m_parameters; }
164 
165     /**
166      * <p>Default parameter substitution placeholders to set in the job definition.
167      * Parameters are specified as a key-value pair mapping. Parameters in a
168      * <code>SubmitJob</code> request override any corresponding parameter defaults
169      * from the job definition.</p>
170      */
ParametersHasBeenSet()171     inline bool ParametersHasBeenSet() const { return m_parametersHasBeenSet; }
172 
173     /**
174      * <p>Default parameter substitution placeholders to set in the job definition.
175      * Parameters are specified as a key-value pair mapping. Parameters in a
176      * <code>SubmitJob</code> request override any corresponding parameter defaults
177      * from the job definition.</p>
178      */
SetParameters(const Aws::Map<Aws::String,Aws::String> & value)179     inline void SetParameters(const Aws::Map<Aws::String, Aws::String>& value) { m_parametersHasBeenSet = true; m_parameters = value; }
180 
181     /**
182      * <p>Default parameter substitution placeholders to set in the job definition.
183      * Parameters are specified as a key-value pair mapping. Parameters in a
184      * <code>SubmitJob</code> request override any corresponding parameter defaults
185      * from the job definition.</p>
186      */
SetParameters(Aws::Map<Aws::String,Aws::String> && value)187     inline void SetParameters(Aws::Map<Aws::String, Aws::String>&& value) { m_parametersHasBeenSet = true; m_parameters = std::move(value); }
188 
189     /**
190      * <p>Default parameter substitution placeholders to set in the job definition.
191      * Parameters are specified as a key-value pair mapping. Parameters in a
192      * <code>SubmitJob</code> request override any corresponding parameter defaults
193      * from the job definition.</p>
194      */
WithParameters(const Aws::Map<Aws::String,Aws::String> & value)195     inline RegisterJobDefinitionRequest& WithParameters(const Aws::Map<Aws::String, Aws::String>& value) { SetParameters(value); return *this;}
196 
197     /**
198      * <p>Default parameter substitution placeholders to set in the job definition.
199      * Parameters are specified as a key-value pair mapping. Parameters in a
200      * <code>SubmitJob</code> request override any corresponding parameter defaults
201      * from the job definition.</p>
202      */
WithParameters(Aws::Map<Aws::String,Aws::String> && value)203     inline RegisterJobDefinitionRequest& WithParameters(Aws::Map<Aws::String, Aws::String>&& value) { SetParameters(std::move(value)); return *this;}
204 
205     /**
206      * <p>Default parameter substitution placeholders to set in the job definition.
207      * Parameters are specified as a key-value pair mapping. Parameters in a
208      * <code>SubmitJob</code> request override any corresponding parameter defaults
209      * from the job definition.</p>
210      */
AddParameters(const Aws::String & key,const Aws::String & value)211     inline RegisterJobDefinitionRequest& AddParameters(const Aws::String& key, const Aws::String& value) { m_parametersHasBeenSet = true; m_parameters.emplace(key, value); return *this; }
212 
213     /**
214      * <p>Default parameter substitution placeholders to set in the job definition.
215      * Parameters are specified as a key-value pair mapping. Parameters in a
216      * <code>SubmitJob</code> request override any corresponding parameter defaults
217      * from the job definition.</p>
218      */
AddParameters(Aws::String && key,const Aws::String & value)219     inline RegisterJobDefinitionRequest& AddParameters(Aws::String&& key, const Aws::String& value) { m_parametersHasBeenSet = true; m_parameters.emplace(std::move(key), value); return *this; }
220 
221     /**
222      * <p>Default parameter substitution placeholders to set in the job definition.
223      * Parameters are specified as a key-value pair mapping. Parameters in a
224      * <code>SubmitJob</code> request override any corresponding parameter defaults
225      * from the job definition.</p>
226      */
AddParameters(const Aws::String & key,Aws::String && value)227     inline RegisterJobDefinitionRequest& AddParameters(const Aws::String& key, Aws::String&& value) { m_parametersHasBeenSet = true; m_parameters.emplace(key, std::move(value)); return *this; }
228 
229     /**
230      * <p>Default parameter substitution placeholders to set in the job definition.
231      * Parameters are specified as a key-value pair mapping. Parameters in a
232      * <code>SubmitJob</code> request override any corresponding parameter defaults
233      * from the job definition.</p>
234      */
AddParameters(Aws::String && key,Aws::String && value)235     inline RegisterJobDefinitionRequest& AddParameters(Aws::String&& key, Aws::String&& value) { m_parametersHasBeenSet = true; m_parameters.emplace(std::move(key), std::move(value)); return *this; }
236 
237     /**
238      * <p>Default parameter substitution placeholders to set in the job definition.
239      * Parameters are specified as a key-value pair mapping. Parameters in a
240      * <code>SubmitJob</code> request override any corresponding parameter defaults
241      * from the job definition.</p>
242      */
AddParameters(const char * key,Aws::String && value)243     inline RegisterJobDefinitionRequest& AddParameters(const char* key, Aws::String&& value) { m_parametersHasBeenSet = true; m_parameters.emplace(key, std::move(value)); return *this; }
244 
245     /**
246      * <p>Default parameter substitution placeholders to set in the job definition.
247      * Parameters are specified as a key-value pair mapping. Parameters in a
248      * <code>SubmitJob</code> request override any corresponding parameter defaults
249      * from the job definition.</p>
250      */
AddParameters(Aws::String && key,const char * value)251     inline RegisterJobDefinitionRequest& AddParameters(Aws::String&& key, const char* value) { m_parametersHasBeenSet = true; m_parameters.emplace(std::move(key), value); return *this; }
252 
253     /**
254      * <p>Default parameter substitution placeholders to set in the job definition.
255      * Parameters are specified as a key-value pair mapping. Parameters in a
256      * <code>SubmitJob</code> request override any corresponding parameter defaults
257      * from the job definition.</p>
258      */
AddParameters(const char * key,const char * value)259     inline RegisterJobDefinitionRequest& AddParameters(const char* key, const char* value) { m_parametersHasBeenSet = true; m_parameters.emplace(key, value); return *this; }
260 
261 
262     /**
263      * <p>An object with various properties specific to single-node container-based
264      * jobs. If the job definition's <code>type</code> parameter is
265      * <code>container</code>, then you must specify either
266      * <code>containerProperties</code> or <code>nodeProperties</code>.</p>
267      * <p>If the job runs on Fargate resources, then you must not specify
268      * <code>nodeProperties</code>; use only <code>containerProperties</code>.</p>
269      *
270      */
GetContainerProperties()271     inline const ContainerProperties& GetContainerProperties() const{ return m_containerProperties; }
272 
273     /**
274      * <p>An object with various properties specific to single-node container-based
275      * jobs. If the job definition's <code>type</code> parameter is
276      * <code>container</code>, then you must specify either
277      * <code>containerProperties</code> or <code>nodeProperties</code>.</p>
278      * <p>If the job runs on Fargate resources, then you must not specify
279      * <code>nodeProperties</code>; use only <code>containerProperties</code>.</p>
280      *
281      */
ContainerPropertiesHasBeenSet()282     inline bool ContainerPropertiesHasBeenSet() const { return m_containerPropertiesHasBeenSet; }
283 
284     /**
285      * <p>An object with various properties specific to single-node container-based
286      * jobs. If the job definition's <code>type</code> parameter is
287      * <code>container</code>, then you must specify either
288      * <code>containerProperties</code> or <code>nodeProperties</code>.</p>
289      * <p>If the job runs on Fargate resources, then you must not specify
290      * <code>nodeProperties</code>; use only <code>containerProperties</code>.</p>
291      *
292      */
SetContainerProperties(const ContainerProperties & value)293     inline void SetContainerProperties(const ContainerProperties& value) { m_containerPropertiesHasBeenSet = true; m_containerProperties = value; }
294 
295     /**
296      * <p>An object with various properties specific to single-node container-based
297      * jobs. If the job definition's <code>type</code> parameter is
298      * <code>container</code>, then you must specify either
299      * <code>containerProperties</code> or <code>nodeProperties</code>.</p>
300      * <p>If the job runs on Fargate resources, then you must not specify
301      * <code>nodeProperties</code>; use only <code>containerProperties</code>.</p>
302      *
303      */
SetContainerProperties(ContainerProperties && value)304     inline void SetContainerProperties(ContainerProperties&& value) { m_containerPropertiesHasBeenSet = true; m_containerProperties = std::move(value); }
305 
306     /**
307      * <p>An object with various properties specific to single-node container-based
308      * jobs. If the job definition's <code>type</code> parameter is
309      * <code>container</code>, then you must specify either
310      * <code>containerProperties</code> or <code>nodeProperties</code>.</p>
311      * <p>If the job runs on Fargate resources, then you must not specify
312      * <code>nodeProperties</code>; use only <code>containerProperties</code>.</p>
313      *
314      */
WithContainerProperties(const ContainerProperties & value)315     inline RegisterJobDefinitionRequest& WithContainerProperties(const ContainerProperties& value) { SetContainerProperties(value); return *this;}
316 
317     /**
318      * <p>An object with various properties specific to single-node container-based
319      * jobs. If the job definition's <code>type</code> parameter is
320      * <code>container</code>, then you must specify either
321      * <code>containerProperties</code> or <code>nodeProperties</code>.</p>
322      * <p>If the job runs on Fargate resources, then you must not specify
323      * <code>nodeProperties</code>; use only <code>containerProperties</code>.</p>
324      *
325      */
WithContainerProperties(ContainerProperties && value)326     inline RegisterJobDefinitionRequest& WithContainerProperties(ContainerProperties&& value) { SetContainerProperties(std::move(value)); return *this;}
327 
328 
329     /**
330      * <p>An object with various properties specific to multi-node parallel jobs. If
331      * you specify node properties for a job, it becomes a multi-node parallel job. For
332      * more information, see <a
333      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-parallel-jobs.html">Multi-node
334      * Parallel Jobs</a> in the <i>Batch User Guide</i>. If the job definition's
335      * <code>type</code> parameter is <code>container</code>, then you must specify
336      * either <code>containerProperties</code> or <code>nodeProperties</code>.</p>
337      *  <p>If the job runs on Fargate resources, then you must not specify
338      * <code>nodeProperties</code>; use <code>containerProperties</code> instead.</p>
339      *
340      */
GetNodeProperties()341     inline const NodeProperties& GetNodeProperties() const{ return m_nodeProperties; }
342 
343     /**
344      * <p>An object with various properties specific to multi-node parallel jobs. If
345      * you specify node properties for a job, it becomes a multi-node parallel job. For
346      * more information, see <a
347      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-parallel-jobs.html">Multi-node
348      * Parallel Jobs</a> in the <i>Batch User Guide</i>. If the job definition's
349      * <code>type</code> parameter is <code>container</code>, then you must specify
350      * either <code>containerProperties</code> or <code>nodeProperties</code>.</p>
351      *  <p>If the job runs on Fargate resources, then you must not specify
352      * <code>nodeProperties</code>; use <code>containerProperties</code> instead.</p>
353      *
354      */
NodePropertiesHasBeenSet()355     inline bool NodePropertiesHasBeenSet() const { return m_nodePropertiesHasBeenSet; }
356 
357     /**
358      * <p>An object with various properties specific to multi-node parallel jobs. If
359      * you specify node properties for a job, it becomes a multi-node parallel job. For
360      * more information, see <a
361      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-parallel-jobs.html">Multi-node
362      * Parallel Jobs</a> in the <i>Batch User Guide</i>. If the job definition's
363      * <code>type</code> parameter is <code>container</code>, then you must specify
364      * either <code>containerProperties</code> or <code>nodeProperties</code>.</p>
365      *  <p>If the job runs on Fargate resources, then you must not specify
366      * <code>nodeProperties</code>; use <code>containerProperties</code> instead.</p>
367      *
368      */
SetNodeProperties(const NodeProperties & value)369     inline void SetNodeProperties(const NodeProperties& value) { m_nodePropertiesHasBeenSet = true; m_nodeProperties = value; }
370 
371     /**
372      * <p>An object with various properties specific to multi-node parallel jobs. If
373      * you specify node properties for a job, it becomes a multi-node parallel job. For
374      * more information, see <a
375      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-parallel-jobs.html">Multi-node
376      * Parallel Jobs</a> in the <i>Batch User Guide</i>. If the job definition's
377      * <code>type</code> parameter is <code>container</code>, then you must specify
378      * either <code>containerProperties</code> or <code>nodeProperties</code>.</p>
379      *  <p>If the job runs on Fargate resources, then you must not specify
380      * <code>nodeProperties</code>; use <code>containerProperties</code> instead.</p>
381      *
382      */
SetNodeProperties(NodeProperties && value)383     inline void SetNodeProperties(NodeProperties&& value) { m_nodePropertiesHasBeenSet = true; m_nodeProperties = std::move(value); }
384 
385     /**
386      * <p>An object with various properties specific to multi-node parallel jobs. If
387      * you specify node properties for a job, it becomes a multi-node parallel job. For
388      * more information, see <a
389      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-parallel-jobs.html">Multi-node
390      * Parallel Jobs</a> in the <i>Batch User Guide</i>. If the job definition's
391      * <code>type</code> parameter is <code>container</code>, then you must specify
392      * either <code>containerProperties</code> or <code>nodeProperties</code>.</p>
393      *  <p>If the job runs on Fargate resources, then you must not specify
394      * <code>nodeProperties</code>; use <code>containerProperties</code> instead.</p>
395      *
396      */
WithNodeProperties(const NodeProperties & value)397     inline RegisterJobDefinitionRequest& WithNodeProperties(const NodeProperties& value) { SetNodeProperties(value); return *this;}
398 
399     /**
400      * <p>An object with various properties specific to multi-node parallel jobs. If
401      * you specify node properties for a job, it becomes a multi-node parallel job. For
402      * more information, see <a
403      * href="https://docs.aws.amazon.com/batch/latest/userguide/multi-node-parallel-jobs.html">Multi-node
404      * Parallel Jobs</a> in the <i>Batch User Guide</i>. If the job definition's
405      * <code>type</code> parameter is <code>container</code>, then you must specify
406      * either <code>containerProperties</code> or <code>nodeProperties</code>.</p>
407      *  <p>If the job runs on Fargate resources, then you must not specify
408      * <code>nodeProperties</code>; use <code>containerProperties</code> instead.</p>
409      *
410      */
WithNodeProperties(NodeProperties && value)411     inline RegisterJobDefinitionRequest& WithNodeProperties(NodeProperties&& value) { SetNodeProperties(std::move(value)); return *this;}
412 
413 
414     /**
415      * <p>The retry strategy to use for failed jobs that are submitted with this job
416      * definition. Any retry strategy that's specified during a <a>SubmitJob</a>
417      * operation overrides the retry strategy defined here. If a job is terminated due
418      * to a timeout, it isn't retried.</p>
419      */
GetRetryStrategy()420     inline const RetryStrategy& GetRetryStrategy() const{ return m_retryStrategy; }
421 
422     /**
423      * <p>The retry strategy to use for failed jobs that are submitted with this job
424      * definition. Any retry strategy that's specified during a <a>SubmitJob</a>
425      * operation overrides the retry strategy defined here. If a job is terminated due
426      * to a timeout, it isn't retried.</p>
427      */
RetryStrategyHasBeenSet()428     inline bool RetryStrategyHasBeenSet() const { return m_retryStrategyHasBeenSet; }
429 
430     /**
431      * <p>The retry strategy to use for failed jobs that are submitted with this job
432      * definition. Any retry strategy that's specified during a <a>SubmitJob</a>
433      * operation overrides the retry strategy defined here. If a job is terminated due
434      * to a timeout, it isn't retried.</p>
435      */
SetRetryStrategy(const RetryStrategy & value)436     inline void SetRetryStrategy(const RetryStrategy& value) { m_retryStrategyHasBeenSet = true; m_retryStrategy = value; }
437 
438     /**
439      * <p>The retry strategy to use for failed jobs that are submitted with this job
440      * definition. Any retry strategy that's specified during a <a>SubmitJob</a>
441      * operation overrides the retry strategy defined here. If a job is terminated due
442      * to a timeout, it isn't retried.</p>
443      */
SetRetryStrategy(RetryStrategy && value)444     inline void SetRetryStrategy(RetryStrategy&& value) { m_retryStrategyHasBeenSet = true; m_retryStrategy = std::move(value); }
445 
446     /**
447      * <p>The retry strategy to use for failed jobs that are submitted with this job
448      * definition. Any retry strategy that's specified during a <a>SubmitJob</a>
449      * operation overrides the retry strategy defined here. If a job is terminated due
450      * to a timeout, it isn't retried.</p>
451      */
WithRetryStrategy(const RetryStrategy & value)452     inline RegisterJobDefinitionRequest& WithRetryStrategy(const RetryStrategy& value) { SetRetryStrategy(value); return *this;}
453 
454     /**
455      * <p>The retry strategy to use for failed jobs that are submitted with this job
456      * definition. Any retry strategy that's specified during a <a>SubmitJob</a>
457      * operation overrides the retry strategy defined here. If a job is terminated due
458      * to a timeout, it isn't retried.</p>
459      */
WithRetryStrategy(RetryStrategy && value)460     inline RegisterJobDefinitionRequest& WithRetryStrategy(RetryStrategy&& value) { SetRetryStrategy(std::move(value)); return *this;}
461 
462 
463     /**
464      * <p>Specifies whether to propagate the tags from the job or job definition to the
465      * corresponding Amazon ECS task. If no value is specified, the tags are not
466      * propagated. Tags can only be propagated to the tasks during task creation. For
467      * tags with the same name, job tags are given priority over job definitions tags.
468      * If the total number of combined tags from the job and job definition is over 50,
469      * the job is moved to the <code>FAILED</code> state.</p>
470      */
GetPropagateTags()471     inline bool GetPropagateTags() const{ return m_propagateTags; }
472 
473     /**
474      * <p>Specifies whether to propagate the tags from the job or job definition to the
475      * corresponding Amazon ECS task. If no value is specified, the tags are not
476      * propagated. Tags can only be propagated to the tasks during task creation. For
477      * tags with the same name, job tags are given priority over job definitions tags.
478      * If the total number of combined tags from the job and job definition is over 50,
479      * the job is moved to the <code>FAILED</code> state.</p>
480      */
PropagateTagsHasBeenSet()481     inline bool PropagateTagsHasBeenSet() const { return m_propagateTagsHasBeenSet; }
482 
483     /**
484      * <p>Specifies whether to propagate the tags from the job or job definition to the
485      * corresponding Amazon ECS task. If no value is specified, the tags are not
486      * propagated. Tags can only be propagated to the tasks during task creation. For
487      * tags with the same name, job tags are given priority over job definitions tags.
488      * If the total number of combined tags from the job and job definition is over 50,
489      * the job is moved to the <code>FAILED</code> state.</p>
490      */
SetPropagateTags(bool value)491     inline void SetPropagateTags(bool value) { m_propagateTagsHasBeenSet = true; m_propagateTags = value; }
492 
493     /**
494      * <p>Specifies whether to propagate the tags from the job or job definition to the
495      * corresponding Amazon ECS task. If no value is specified, the tags are not
496      * propagated. Tags can only be propagated to the tasks during task creation. For
497      * tags with the same name, job tags are given priority over job definitions tags.
498      * If the total number of combined tags from the job and job definition is over 50,
499      * the job is moved to the <code>FAILED</code> state.</p>
500      */
WithPropagateTags(bool value)501     inline RegisterJobDefinitionRequest& WithPropagateTags(bool value) { SetPropagateTags(value); return *this;}
502 
503 
504     /**
505      * <p>The timeout configuration for jobs that are submitted with this job
506      * definition, after which Batch terminates your jobs if they have not finished. If
507      * a job is terminated due to a timeout, it isn't retried. The minimum value for
508      * the timeout is 60 seconds. Any timeout configuration that's specified during a
509      * <a>SubmitJob</a> operation overrides the timeout configuration defined here. For
510      * more information, see <a
511      * href="https://docs.aws.amazon.com/batch/latest/userguide/job_timeouts.html">Job
512      * Timeouts</a> in the <i>Batch User Guide</i>.</p>
513      */
GetTimeout()514     inline const JobTimeout& GetTimeout() const{ return m_timeout; }
515 
516     /**
517      * <p>The timeout configuration for jobs that are submitted with this job
518      * definition, after which Batch terminates your jobs if they have not finished. If
519      * a job is terminated due to a timeout, it isn't retried. The minimum value for
520      * the timeout is 60 seconds. Any timeout configuration that's specified during a
521      * <a>SubmitJob</a> operation overrides the timeout configuration defined here. For
522      * more information, see <a
523      * href="https://docs.aws.amazon.com/batch/latest/userguide/job_timeouts.html">Job
524      * Timeouts</a> in the <i>Batch User Guide</i>.</p>
525      */
TimeoutHasBeenSet()526     inline bool TimeoutHasBeenSet() const { return m_timeoutHasBeenSet; }
527 
528     /**
529      * <p>The timeout configuration for jobs that are submitted with this job
530      * definition, after which Batch terminates your jobs if they have not finished. If
531      * a job is terminated due to a timeout, it isn't retried. The minimum value for
532      * the timeout is 60 seconds. Any timeout configuration that's specified during a
533      * <a>SubmitJob</a> operation overrides the timeout configuration defined here. For
534      * more information, see <a
535      * href="https://docs.aws.amazon.com/batch/latest/userguide/job_timeouts.html">Job
536      * Timeouts</a> in the <i>Batch User Guide</i>.</p>
537      */
SetTimeout(const JobTimeout & value)538     inline void SetTimeout(const JobTimeout& value) { m_timeoutHasBeenSet = true; m_timeout = value; }
539 
540     /**
541      * <p>The timeout configuration for jobs that are submitted with this job
542      * definition, after which Batch terminates your jobs if they have not finished. If
543      * a job is terminated due to a timeout, it isn't retried. The minimum value for
544      * the timeout is 60 seconds. Any timeout configuration that's specified during a
545      * <a>SubmitJob</a> operation overrides the timeout configuration defined here. For
546      * more information, see <a
547      * href="https://docs.aws.amazon.com/batch/latest/userguide/job_timeouts.html">Job
548      * Timeouts</a> in the <i>Batch User Guide</i>.</p>
549      */
SetTimeout(JobTimeout && value)550     inline void SetTimeout(JobTimeout&& value) { m_timeoutHasBeenSet = true; m_timeout = std::move(value); }
551 
552     /**
553      * <p>The timeout configuration for jobs that are submitted with this job
554      * definition, after which Batch terminates your jobs if they have not finished. If
555      * a job is terminated due to a timeout, it isn't retried. The minimum value for
556      * the timeout is 60 seconds. Any timeout configuration that's specified during a
557      * <a>SubmitJob</a> operation overrides the timeout configuration defined here. For
558      * more information, see <a
559      * href="https://docs.aws.amazon.com/batch/latest/userguide/job_timeouts.html">Job
560      * Timeouts</a> in the <i>Batch User Guide</i>.</p>
561      */
WithTimeout(const JobTimeout & value)562     inline RegisterJobDefinitionRequest& WithTimeout(const JobTimeout& value) { SetTimeout(value); return *this;}
563 
564     /**
565      * <p>The timeout configuration for jobs that are submitted with this job
566      * definition, after which Batch terminates your jobs if they have not finished. If
567      * a job is terminated due to a timeout, it isn't retried. The minimum value for
568      * the timeout is 60 seconds. Any timeout configuration that's specified during a
569      * <a>SubmitJob</a> operation overrides the timeout configuration defined here. For
570      * more information, see <a
571      * href="https://docs.aws.amazon.com/batch/latest/userguide/job_timeouts.html">Job
572      * Timeouts</a> in the <i>Batch User Guide</i>.</p>
573      */
WithTimeout(JobTimeout && value)574     inline RegisterJobDefinitionRequest& WithTimeout(JobTimeout&& value) { SetTimeout(std::move(value)); return *this;}
575 
576 
577     /**
578      * <p>The tags that you apply to the job definition to help you categorize and
579      * organize your resources. Each tag consists of a key and an optional value. For
580      * more information, see <a
581      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
582      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
583      */
GetTags()584     inline const Aws::Map<Aws::String, Aws::String>& GetTags() const{ return m_tags; }
585 
586     /**
587      * <p>The tags that you apply to the job definition to help you categorize and
588      * organize your resources. Each tag consists of a key and an optional value. For
589      * more information, see <a
590      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
591      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
592      */
TagsHasBeenSet()593     inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
594 
595     /**
596      * <p>The tags that you apply to the job definition to help you categorize and
597      * organize your resources. Each tag consists of a key and an optional value. For
598      * more information, see <a
599      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
600      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
601      */
SetTags(const Aws::Map<Aws::String,Aws::String> & value)602     inline void SetTags(const Aws::Map<Aws::String, Aws::String>& value) { m_tagsHasBeenSet = true; m_tags = value; }
603 
604     /**
605      * <p>The tags that you apply to the job definition to help you categorize and
606      * organize your resources. Each tag consists of a key and an optional value. For
607      * more information, see <a
608      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
609      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
610      */
SetTags(Aws::Map<Aws::String,Aws::String> && value)611     inline void SetTags(Aws::Map<Aws::String, Aws::String>&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); }
612 
613     /**
614      * <p>The tags that you apply to the job definition to help you categorize and
615      * organize your resources. Each tag consists of a key and an optional value. For
616      * more information, see <a
617      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
618      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
619      */
WithTags(const Aws::Map<Aws::String,Aws::String> & value)620     inline RegisterJobDefinitionRequest& WithTags(const Aws::Map<Aws::String, Aws::String>& value) { SetTags(value); return *this;}
621 
622     /**
623      * <p>The tags that you apply to the job definition to help you categorize and
624      * organize your resources. Each tag consists of a key and an optional value. For
625      * more information, see <a
626      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
627      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
628      */
WithTags(Aws::Map<Aws::String,Aws::String> && value)629     inline RegisterJobDefinitionRequest& WithTags(Aws::Map<Aws::String, Aws::String>&& value) { SetTags(std::move(value)); return *this;}
630 
631     /**
632      * <p>The tags that you apply to the job definition to help you categorize and
633      * organize your resources. Each tag consists of a key and an optional value. For
634      * more information, see <a
635      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
636      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
637      */
AddTags(const Aws::String & key,const Aws::String & value)638     inline RegisterJobDefinitionRequest& AddTags(const Aws::String& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; }
639 
640     /**
641      * <p>The tags that you apply to the job definition to help you categorize and
642      * organize your resources. Each tag consists of a key and an optional value. For
643      * more information, see <a
644      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
645      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
646      */
AddTags(Aws::String && key,const Aws::String & value)647     inline RegisterJobDefinitionRequest& AddTags(Aws::String&& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; }
648 
649     /**
650      * <p>The tags that you apply to the job definition to help you categorize and
651      * organize your resources. Each tag consists of a key and an optional value. For
652      * more information, see <a
653      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
654      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
655      */
AddTags(const Aws::String & key,Aws::String && value)656     inline RegisterJobDefinitionRequest& AddTags(const Aws::String& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; }
657 
658     /**
659      * <p>The tags that you apply to the job definition to help you categorize and
660      * organize your resources. Each tag consists of a key and an optional value. For
661      * more information, see <a
662      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
663      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
664      */
AddTags(Aws::String && key,Aws::String && value)665     inline RegisterJobDefinitionRequest& AddTags(Aws::String&& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), std::move(value)); return *this; }
666 
667     /**
668      * <p>The tags that you apply to the job definition to help you categorize and
669      * organize your resources. Each tag consists of a key and an optional value. For
670      * more information, see <a
671      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
672      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
673      */
AddTags(const char * key,Aws::String && value)674     inline RegisterJobDefinitionRequest& AddTags(const char* key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; }
675 
676     /**
677      * <p>The tags that you apply to the job definition to help you categorize and
678      * organize your resources. Each tag consists of a key and an optional value. For
679      * more information, see <a
680      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
681      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
682      */
AddTags(Aws::String && key,const char * value)683     inline RegisterJobDefinitionRequest& AddTags(Aws::String&& key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; }
684 
685     /**
686      * <p>The tags that you apply to the job definition to help you categorize and
687      * organize your resources. Each tag consists of a key and an optional value. For
688      * more information, see <a
689      * href="https://docs.aws.amazon.com/batch/latest/userguide/using-tags.html">Tagging
690      * Amazon Web Services Resources</a> in <i>Batch User Guide</i>.</p>
691      */
AddTags(const char * key,const char * value)692     inline RegisterJobDefinitionRequest& AddTags(const char* key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; }
693 
694 
695     /**
696      * <p>The platform capabilities required by the job definition. If no value is
697      * specified, it defaults to <code>EC2</code>. To run the job on Fargate resources,
698      * specify <code>FARGATE</code>.</p>
699      */
GetPlatformCapabilities()700     inline const Aws::Vector<PlatformCapability>& GetPlatformCapabilities() const{ return m_platformCapabilities; }
701 
702     /**
703      * <p>The platform capabilities required by the job definition. If no value is
704      * specified, it defaults to <code>EC2</code>. To run the job on Fargate resources,
705      * specify <code>FARGATE</code>.</p>
706      */
PlatformCapabilitiesHasBeenSet()707     inline bool PlatformCapabilitiesHasBeenSet() const { return m_platformCapabilitiesHasBeenSet; }
708 
709     /**
710      * <p>The platform capabilities required by the job definition. If no value is
711      * specified, it defaults to <code>EC2</code>. To run the job on Fargate resources,
712      * specify <code>FARGATE</code>.</p>
713      */
SetPlatformCapabilities(const Aws::Vector<PlatformCapability> & value)714     inline void SetPlatformCapabilities(const Aws::Vector<PlatformCapability>& value) { m_platformCapabilitiesHasBeenSet = true; m_platformCapabilities = value; }
715 
716     /**
717      * <p>The platform capabilities required by the job definition. If no value is
718      * specified, it defaults to <code>EC2</code>. To run the job on Fargate resources,
719      * specify <code>FARGATE</code>.</p>
720      */
SetPlatformCapabilities(Aws::Vector<PlatformCapability> && value)721     inline void SetPlatformCapabilities(Aws::Vector<PlatformCapability>&& value) { m_platformCapabilitiesHasBeenSet = true; m_platformCapabilities = std::move(value); }
722 
723     /**
724      * <p>The platform capabilities required by the job definition. If no value is
725      * specified, it defaults to <code>EC2</code>. To run the job on Fargate resources,
726      * specify <code>FARGATE</code>.</p>
727      */
WithPlatformCapabilities(const Aws::Vector<PlatformCapability> & value)728     inline RegisterJobDefinitionRequest& WithPlatformCapabilities(const Aws::Vector<PlatformCapability>& value) { SetPlatformCapabilities(value); return *this;}
729 
730     /**
731      * <p>The platform capabilities required by the job definition. If no value is
732      * specified, it defaults to <code>EC2</code>. To run the job on Fargate resources,
733      * specify <code>FARGATE</code>.</p>
734      */
WithPlatformCapabilities(Aws::Vector<PlatformCapability> && value)735     inline RegisterJobDefinitionRequest& WithPlatformCapabilities(Aws::Vector<PlatformCapability>&& value) { SetPlatformCapabilities(std::move(value)); return *this;}
736 
737     /**
738      * <p>The platform capabilities required by the job definition. If no value is
739      * specified, it defaults to <code>EC2</code>. To run the job on Fargate resources,
740      * specify <code>FARGATE</code>.</p>
741      */
AddPlatformCapabilities(const PlatformCapability & value)742     inline RegisterJobDefinitionRequest& AddPlatformCapabilities(const PlatformCapability& value) { m_platformCapabilitiesHasBeenSet = true; m_platformCapabilities.push_back(value); return *this; }
743 
744     /**
745      * <p>The platform capabilities required by the job definition. If no value is
746      * specified, it defaults to <code>EC2</code>. To run the job on Fargate resources,
747      * specify <code>FARGATE</code>.</p>
748      */
AddPlatformCapabilities(PlatformCapability && value)749     inline RegisterJobDefinitionRequest& AddPlatformCapabilities(PlatformCapability&& value) { m_platformCapabilitiesHasBeenSet = true; m_platformCapabilities.push_back(std::move(value)); return *this; }
750 
751   private:
752 
753     Aws::String m_jobDefinitionName;
754     bool m_jobDefinitionNameHasBeenSet;
755 
756     JobDefinitionType m_type;
757     bool m_typeHasBeenSet;
758 
759     Aws::Map<Aws::String, Aws::String> m_parameters;
760     bool m_parametersHasBeenSet;
761 
762     ContainerProperties m_containerProperties;
763     bool m_containerPropertiesHasBeenSet;
764 
765     NodeProperties m_nodeProperties;
766     bool m_nodePropertiesHasBeenSet;
767 
768     RetryStrategy m_retryStrategy;
769     bool m_retryStrategyHasBeenSet;
770 
771     bool m_propagateTags;
772     bool m_propagateTagsHasBeenSet;
773 
774     JobTimeout m_timeout;
775     bool m_timeoutHasBeenSet;
776 
777     Aws::Map<Aws::String, Aws::String> m_tags;
778     bool m_tagsHasBeenSet;
779 
780     Aws::Vector<PlatformCapability> m_platformCapabilities;
781     bool m_platformCapabilitiesHasBeenSet;
782   };
783 
784 } // namespace Model
785 } // namespace Batch
786 } // namespace Aws
787