/* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ /* * Do not modify this file. This file is generated from the batch-2016-08-10.normal.json service model. */ using System; using System.Collections.Generic; using System.Xml.Serialization; using System.Text; using System.IO; using System.Net; using Amazon.Runtime; using Amazon.Runtime.Internal; namespace Amazon.Batch.Model { /// /// An object that represents an Batch job definition. /// public partial class JobDefinition { private OrchestrationType _containerOrchestrationType; private ContainerProperties _containerProperties; private EksProperties _eksProperties; private string _jobDefinitionArn; private string _jobDefinitionName; private NodeProperties _nodeProperties; private Dictionary _parameters = new Dictionary(); private List _platformCapabilities = new List(); private bool? _propagateTags; private RetryStrategy _retryStrategy; private int? _revision; private int? _schedulingPriority; private string _status; private Dictionary _tags = new Dictionary(); private JobTimeout _timeout; private string _type; /// /// Gets and sets the property ContainerOrchestrationType. /// /// The orchestration type of the compute environment. The valid values are ECS /// (default) or EKS. /// /// public OrchestrationType ContainerOrchestrationType { get { return this._containerOrchestrationType; } set { this._containerOrchestrationType = value; } } // Check to see if ContainerOrchestrationType property is set internal bool IsSetContainerOrchestrationType() { return this._containerOrchestrationType != null; } /// /// Gets and sets the property ContainerProperties. /// /// An object with various properties specific to Amazon ECS based jobs. Valid values /// are containerProperties, eksProperties, and nodeProperties. /// Only one can be specified. /// /// public ContainerProperties ContainerProperties { get { return this._containerProperties; } set { this._containerProperties = value; } } // Check to see if ContainerProperties property is set internal bool IsSetContainerProperties() { return this._containerProperties != null; } /// /// Gets and sets the property EksProperties. /// /// An object with various properties that are specific to Amazon EKS based jobs. Valid /// values are containerProperties, eksProperties, and nodeProperties. /// Only one can be specified. /// /// public EksProperties EksProperties { get { return this._eksProperties; } set { this._eksProperties = value; } } // Check to see if EksProperties property is set internal bool IsSetEksProperties() { return this._eksProperties != null; } /// /// Gets and sets the property JobDefinitionArn. /// /// The Amazon Resource Name (ARN) for the job definition. /// /// [AWSProperty(Required=true)] public string JobDefinitionArn { get { return this._jobDefinitionArn; } set { this._jobDefinitionArn = value; } } // Check to see if JobDefinitionArn property is set internal bool IsSetJobDefinitionArn() { return this._jobDefinitionArn != null; } /// /// Gets and sets the property JobDefinitionName. /// /// The name of the job definition. /// /// [AWSProperty(Required=true)] public string JobDefinitionName { get { return this._jobDefinitionName; } set { this._jobDefinitionName = value; } } // Check to see if JobDefinitionName property is set internal bool IsSetJobDefinitionName() { return this._jobDefinitionName != null; } /// /// Gets and sets the property NodeProperties. /// /// An object with various properties that are specific to multi-node parallel jobs. Valid /// values are containerProperties, eksProperties, and nodeProperties. /// Only one can be specified. /// /// /// /// If the job runs on Fargate resources, don't specify nodeProperties. Use /// containerProperties instead. /// /// /// public NodeProperties NodeProperties { get { return this._nodeProperties; } set { this._nodeProperties = value; } } // Check to see if NodeProperties property is set internal bool IsSetNodeProperties() { return this._nodeProperties != null; } /// /// Gets and sets the property Parameters. /// /// Default parameters or parameter substitution placeholders that are set in the job /// definition. Parameters are specified as a key-value pair mapping. Parameters in a /// SubmitJob request override any corresponding parameter defaults from /// the job definition. For more information about specifying parameters, see Job /// definition parameters in the Batch User Guide. /// /// public Dictionary Parameters { get { return this._parameters; } set { this._parameters = value; } } // Check to see if Parameters property is set internal bool IsSetParameters() { return this._parameters != null && this._parameters.Count > 0; } /// /// Gets and sets the property PlatformCapabilities. /// /// The platform capabilities required by the job definition. If no value is specified, /// it defaults to EC2. Jobs run on Fargate resources specify FARGATE. /// /// public List PlatformCapabilities { get { return this._platformCapabilities; } set { this._platformCapabilities = value; } } // Check to see if PlatformCapabilities property is set internal bool IsSetPlatformCapabilities() { return this._platformCapabilities != null && this._platformCapabilities.Count > 0; } /// /// Gets and sets the property PropagateTags. /// /// Specifies whether to propagate the tags from the job or job definition to the corresponding /// Amazon ECS task. If no value is specified, the tags aren't propagated. Tags can only /// be propagated to the tasks when the tasks are created. For tags with the same name, /// job tags are given priority over job definitions tags. If the total number of combined /// tags from the job and job definition is over 50, the job is moved to the FAILED /// state. /// /// public bool PropagateTags { get { return this._propagateTags.GetValueOrDefault(); } set { this._propagateTags = value; } } // Check to see if PropagateTags property is set internal bool IsSetPropagateTags() { return this._propagateTags.HasValue; } /// /// Gets and sets the property RetryStrategy. /// /// The retry strategy to use for failed jobs that are submitted with this job definition. /// /// public RetryStrategy RetryStrategy { get { return this._retryStrategy; } set { this._retryStrategy = value; } } // Check to see if RetryStrategy property is set internal bool IsSetRetryStrategy() { return this._retryStrategy != null; } /// /// Gets and sets the property Revision. /// /// The revision of the job definition. /// /// [AWSProperty(Required=true)] public int Revision { get { return this._revision.GetValueOrDefault(); } set { this._revision = value; } } // Check to see if Revision property is set internal bool IsSetRevision() { return this._revision.HasValue; } /// /// Gets and sets the property SchedulingPriority. /// /// The scheduling priority of the job definition. This only affects jobs in job queues /// with a fair share policy. Jobs with a higher scheduling priority are scheduled before /// jobs with a lower scheduling priority. /// /// public int SchedulingPriority { get { return this._schedulingPriority.GetValueOrDefault(); } set { this._schedulingPriority = value; } } // Check to see if SchedulingPriority property is set internal bool IsSetSchedulingPriority() { return this._schedulingPriority.HasValue; } /// /// Gets and sets the property Status. /// /// The status of the job definition. /// /// public string Status { get { return this._status; } set { this._status = value; } } // Check to see if Status property is set internal bool IsSetStatus() { return this._status != null; } /// /// Gets and sets the property Tags. /// /// The tags that are applied to the job definition. /// /// [AWSProperty(Min=1, Max=50)] public Dictionary Tags { get { return this._tags; } set { this._tags = value; } } // Check to see if Tags property is set internal bool IsSetTags() { return this._tags != null && this._tags.Count > 0; } /// /// Gets and sets the property Timeout. /// /// The timeout time for jobs that are submitted with this job definition. After the amount /// of time you specify passes, Batch terminates your jobs if they aren't finished. /// /// public JobTimeout Timeout { get { return this._timeout; } set { this._timeout = value; } } // Check to see if Timeout property is set internal bool IsSetTimeout() { return this._timeout != null; } /// /// Gets and sets the property Type. /// /// The type of job definition. It's either container or multinode. /// If the job is run on Fargate resources, then multinode isn't supported. /// For more information about multi-node parallel jobs, see Creating /// a multi-node parallel job definition in the Batch User Guide. /// /// [AWSProperty(Required=true)] public string Type { get { return this._type; } set { this._type = value; } } // Check to see if Type property is set internal bool IsSetType() { return this._type != null; } } }